version: zstack 3.8.0 issue: v3.8 zstack v3... · 2020. 4. 3. · upgrade tutorial / 3 management...

15
Upgrade Tutorial Version: ZStack 3.8.0 Issue: V3.8.0

Upload: others

Post on 20-Aug-2021

8 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Version: ZStack 3.8.0 Issue: V3.8 ZStack V3... · 2020. 4. 3. · Upgrade Tutorial / 3 Management Node Upgrade Issue: V3.8.0 5 • During the upgrade, the proxy server of ZStack will

Upgrade Tutorial

Version: ZStack 3.8.0

Issue: V3.8.0

Page 2: Version: ZStack 3.8.0 Issue: V3.8 ZStack V3... · 2020. 4. 3. · Upgrade Tutorial / 3 Management Node Upgrade Issue: V3.8.0 5 • During the upgrade, the proxy server of ZStack will

Upgrade Tutorial / Copyright Statement

Issue: V3.8.0 I

Copyright Statement

Copyright © 2020 Shanghai Yunzhou Information and Technology Ltd. All rights reserved.

Without its written consent, any organization and any individual do not have the right to extract,

copy any part or all of, and are prohibited to disseminate the contents of this documentation in any

manner.

Trademark

Shanghai Yunzhou Information and Technology Ltd. reserves all rights to its trademarks, including

, but not limited to ZStack and other trademarks in connection with Shanghai Yunzhou Information

and Technology Ltd.

Other trademarks or registered trademarks presented in this documentation are owned or

controlled solely by its proprietaries.

Notice

The products, services, or features that you purchased are all subject to the commercial contract

and terms of Shanghai Yunzhou Information and Technology Ltd., but any part or all of the

foregoing displayed in this documentation may not be in the scope of your purchase or use.

Unless there are additional conventions, Shanghai Yunzhou Information and Technology Ltd. will

not claim any implicit or explicit statement or warranty on the contents of this documentation.

In an event of product version upgrades or other reasons, the contents of this documentation will

be irregularly updated and released. Unless there are additional conventions, this documentat

ion, considered solely as a using manual, will not make any implicit or explicit warranty on all the

statements, information, or suggestions.

Page 3: Version: ZStack 3.8.0 Issue: V3.8 ZStack V3... · 2020. 4. 3. · Upgrade Tutorial / 3 Management Node Upgrade Issue: V3.8.0 5 • During the upgrade, the proxy server of ZStack will

Upgrade Tutorial / Contents

II Issue: V3.8.0

Contents

Copyright Statement................................................................................ I1 Upgrade Mechanism............................................................................ 12 Notice.....................................................................................................33 Management Node Upgrade................................................................4

3.1 Incremental Upgrade........................................................................................................43.2 Offline Upgrade................................................................................................................ 6

Glossary................................................................................................ 10

Page 4: Version: ZStack 3.8.0 Issue: V3.8 ZStack V3... · 2020. 4. 3. · Upgrade Tutorial / 3 Management Node Upgrade Issue: V3.8.0 5 • During the upgrade, the proxy server of ZStack will

Upgrade Tutorial / 1 Upgrade Mechanism

Issue: V3.8.0 1

1 Upgrade Mechanism

Declaration: This Tutorial is applicable to intra-version upgrades (such as the upgrade from an old

c74 version to the latest c74 version) for a single management node. For information about how to

upgrade multiple management nodes in the high availability (HA) scenario, see Cluster Upgrade

in Multi-Management Node HA Tutorial.

The ZStack cloud computing platform includes management node, backup storage, and host.

During the upgrade of ZStack, the three types of nodes are upgraded in the following sequence:

1. Upgrade the local repository of the management node.

2. Upgrade the system environment of the management node, including basic system and the

dependencies.

3. Upgrade the system environment of the backup storage, including basic system and the

dependencies.

4. Upgrade the system environment of the host, including basic system, the dependencies, and

core virtualization tools.

When you upgrade the management node and backup storage according to this Tutorial, the VM

instances in the running state are not affected.

To upgrade the host, perform operations according to different deployment scenarios:

1. Local Storage

• Before you upgrade the host, stop the VM instances that are running on the host.

• In the Local Storage scenario, note that after the host enters the maintenance mode, the VM

instances running on this host will be disabled.

2. Network File System (NFS) Storage

• Before you upgrade the host, migrate the VM instances that are running on the host.

• In the NFS Storage scenario, the VM instances running on the host will be migrated after

the host enters the maintenance mode.

3. Shared Mount Point Storage

• Before you upgrade a host, make clear which storage type is used by the Shared Mount

Point.

Page 5: Version: ZStack 3.8.0 Issue: V3.8 ZStack V3... · 2020. 4. 3. · Upgrade Tutorial / 3 Management Node Upgrade Issue: V3.8.0 5 • During the upgrade, the proxy server of ZStack will

Upgrade Tutorial / 1 Upgrade Mechanism

2 Issue: V3.8.0

• The storage types supported by ZStack include GlusterFS, MooseFS, Lustre, and GPFS. In

the Shared Mount Point Storage scenario, upgrading the operating system of the host

will affect the version dependencies of the host client.

• Before you upgrade the host, we recommend that you contact the official technical support

for a proper upgrade solution.

4. SharedBlock Storage, Ceph Distributed Storage (Commercial or Community Edition)

• Before you upgrade the host, we recommend that you contact the official technical support

for a proper upgrade solution.

• After you upgrade the host, you cannot use the shared volumes in SharedBlock to create

snapshots or scale up. If the attached VM instances are in the running state, you cannot

use the shared volumes to create images online. For more information, contact the official

technical support for help.

Page 6: Version: ZStack 3.8.0 Issue: V3.8 ZStack V3... · 2020. 4. 3. · Upgrade Tutorial / 3 Management Node Upgrade Issue: V3.8.0 5 • During the upgrade, the proxy server of ZStack will

Upgrade Tutorial / 2 Notice

Issue: V3.8.0 3

2 Notice

Before you perform upgrade operations, pay attention to the following information:

1. From ZStack 3.2.0, if you are using c74 ISO and Qemu 2.9, the libvirt version will be

automatically upgraded to 4.1.0.

Note:

• If you deployed the platform with Ceph distributed storage and enabled Cephx (the Ceph

authentication protocol), an error might be reported during CD-ROM hot swapping on the

VM instance. This error is caused because the new libvirt version currently does not

support hot swapping. For more information, contact the official technical support for

help.

• The format of shared volumes in the new libvirt version is upgraded to raw. That is, from

ZStack 3.2.0, the format of shared volumes created in SharedBlock are changed to raw.

In this case, the shared volumes of the raw format cannot be used to create snapshots or

scale up. When the attached VM instances are in the running state, the shared volumes

cannot be used to create images. However, the preceding restrictions will be lifted, and

more features will be provided in later versions of ZStack. For more information, follow our

official website for updates.

• You can disable libvirt auto upgrade by performing the following operations:

Go to /usr/local/zstack/apache-tomcat/webapps/zstack/WEB-INF/classes

/zstack.properties, and set the following parameter in zstack.properties:

updatePkgWhenConnect = false# Disable libvirt auto upgrade. The default value is Ture.

Restart the management node for the setting to take effect.

2. From version 3.7.1, ZStack provides two ISO versions: c76 and c74, either of whose

repositories (repo) are compatible in both versions.

• Version 3.7.1 and later versions will no longer provide c72 ISO for you to install and deploy

new platforms. However, you can upgrade your existing c72 ISO to the latest version. For

information about capacity expansion or system upgrade, contact the official technical

support.

• From 3.7.1, the local repo in c72 will be redirected to c74. If you upgrade your platform

offline, obtain c74 ISO to replace the local repo.

Page 7: Version: ZStack 3.8.0 Issue: V3.8 ZStack V3... · 2020. 4. 3. · Upgrade Tutorial / 3 Management Node Upgrade Issue: V3.8.0 5 • During the upgrade, the proxy server of ZStack will

Upgrade Tutorial / 3 Management Node Upgrade

4 Issue: V3.8.0

3 Management Node Upgrade

This topic describes how to upgrade the platform of c74 version.

• Before the upgrade, make sure that the latest version of c74 OS is installed in both the

management node and the compute node.

• Upgrade the management node only. Then, the compute node will be upgraded automatically.

• Before the upgrade, back up the database.

• During the upgrade, you can access the platform UI and console without affecting the VM

instances that are in the running state.

• After the upgrade, clear the browser caches or refresh the UI of the management node in time.

The platform supports incremental upgrade and offline upgrade.

3.1 Incremental UpgradeZStack supports incremental upgrade, which can improve your upgrade experience.

To perform offline upgrade, you need to download the corresponding ISO, upgrade the local

repo, and then upgrade ZStack. With incremental upgrade, you only need to download the latest

ZStack Installation Package. Then, the installation package automatically detects and matches the

corresponding ISO version.

1. Before you upgrade ZStack online, save the following necessary software package to the /opt

/ directory of the management server:

• ZStack Installation Package

▬ File name: ZStack-installer-3.8.0.bin

▬ Download address: Click here.

2. Then, make sure that the database is backed up.

• Run the following command to back up the database:

[root@zstack-1 ~]# zstack-ctl dump_mysql --file-name zstack-mysql-before-upgrade

Note:

• After you run the preceding command, the backup database will be created in /var/

lib/zstack/mysql-backup/.

Page 8: Version: ZStack 3.8.0 Issue: V3.8 ZStack V3... · 2020. 4. 3. · Upgrade Tutorial / 3 Management Node Upgrade Issue: V3.8.0 5 • During the upgrade, the proxy server of ZStack will

Upgrade Tutorial / 3 Management Node Upgrade

Issue: V3.8.0 5

• During the upgrade, the proxy server of ZStack will be upgraded without affecting data

in the primary storage and backup storage.

• You can use the backup service of ZStack to back up your database at a regular time.

Note:

• The backup service is a separate feature module. To use this service, you need to

purchase the Plus License of the backup service module based on the Base License.

The Plus License cannot be used independently.

3. Run the following command to upgrade the management service of ZStack:

[root@zstack-1 opt]# bash ZStack-installer-3.8.0.bin -u

Note:

• If the root password of your database is the default password zstack.mysql.password of

the system, the upgrade can be done by running the preceding command.

• If the root password of your database is a custom nonblank password, run the following

command to complete the upgrade:

[root@zstack-1 opt]# bash ZStack-installer-3.8.0.bin -u -P MYSQL_ROOT_PASSWORD

4. Upgrade the installation package. Then, the installation package automatically detects and

matches the corresponding ISO version.

• If an earlier ISO version is detected, the local repo will be automatically upgraded to the

latest version, and then ZStack is installed.

Page 9: Version: ZStack 3.8.0 Issue: V3.8 ZStack V3... · 2020. 4. 3. · Upgrade Tutorial / 3 Management Node Upgrade Issue: V3.8.0 5 • During the upgrade, the proxy server of ZStack will

Upgrade Tutorial / 3 Management Node Upgrade

6 Issue: V3.8.0

Figure 3-1: The local repo will be automatically upgraded to the latest version

• If an error is reported during the upgrade of the local repo, you will be promoted to perform

offline upgrade.

Figure 3-2: An error is reported during the upgrade of the local repo

Note:

• The whole process of incremental upgrade must be performed when necessary networks

are connected.

• The incremental upgrade solution allows you to seamlessly upgrade the platform to the

latest version.

3.2 Offline Upgrade1. Before you upgrade ZStack offline, save the following necessary software package to the /opt

/ directory of the management server:

• ZStack Custom ISO

▬ File name: ZStack-x86_64-DVD-3.8.0-c76.iso

▬ Download address: Click here.

Page 10: Version: ZStack 3.8.0 Issue: V3.8 ZStack V3... · 2020. 4. 3. · Upgrade Tutorial / 3 Management Node Upgrade Issue: V3.8.0 5 • During the upgrade, the proxy server of ZStack will

Upgrade Tutorial / 3 Management Node Upgrade

Issue: V3.8.0 7

Note:

Statement on c72 ISO upgrade:

• Version 3.7.1 and later versions will no longer provide c72 ISO for you to install and

deploy new platforms. However, you can upgrade your existing c72 ISO to the latest

version.

• The local repo in c72 is redirected to c74. If you upgrade the platform offline, obtain c74

ISO to replace the local repo.

• ZStack Installation Package

▬ File name: ZStack-installer-3.8.0.bin

▬ Download address: Click here.

• Upgrade Script

▬ File name: zstack-upgrade

▬ Download address: Click here

Note:

The version of the upgrade script must be consistent with the version of the custom ISO

and the installation package.

Note:

After you download the software, check the authentication code by using MD5 and verify that

the code confirms with the release information.

2. Then, make sure that the database is backed up.

• Run the following command to back up the database:

[root@zstack-1 ~]# zstack-ctl dump_mysql --file-name zstack-mysql-before-upgrade

Note:

• After you run the preceding command, the backup database will be created in /var/

lib/zstack/mysql-backup/.

• During the upgrade, the proxy server of ZStack will be upgraded without affecting data

in the primary storage and backup storage.

Page 11: Version: ZStack 3.8.0 Issue: V3.8 ZStack V3... · 2020. 4. 3. · Upgrade Tutorial / 3 Management Node Upgrade Issue: V3.8.0 5 • During the upgrade, the proxy server of ZStack will

Upgrade Tutorial / 3 Management Node Upgrade

8 Issue: V3.8.0

• You can use the backup service of ZStack to back up your database at a regular time.

Note:

• The backup service is a separate feature module. To use this service, you need to

purchase the Plus License of the backup service module based on the Base License.

The Plus License cannot be used independently.

3. Run the following command to upgrade the management service of ZStack:

#The following are two types of offline upgrades:# 1. Upgrade the local repository and the management service at the same time:[root@zstack-1 opt]# bash zstack-upgrade ZStack-x86_64-DVD-3.8.0-c76.iso# 2. Upgrade the local repository and then the management service:[root@zstack-1 opt]# bash zstack-upgrade -r ZStack-x86_64-DVD-3.8.0-c76.iso [root@zstack-1 opt]# bash ZStack-installer-3.8.0.bin -u

Note:

• If the root password of your database is the default password zstack.mysql.password of

the system, the upgrade can be done by running the preceding command.

• If the root password of your database is a custom nonblank password, run the following

commands to complete the upgrade:

#The following are two types of offline upgrades:# 1. Upgrade the local repository and the management service at the same time:[root@zstack-1 opt]# bash zstack-upgrade ZStack-x86_64-DVD-3.8.0-c76.iso# 2. Upgrade the local repository and then the management service:[root@zstack-1 opt]# bash zstack-upgrade -r ZStack-x86_64-DVD-3.8.0-c76.iso [root@zstack-1 opt]# bash ZStack-installer-3.8.0.bin -u -P MYSQL_ROOT_PASSWORD

• Before executing the command zstack-upgrade, conform that the ISO is based on c76.

Avoid the overlap of the local repo with c74 ISO!

4. If the upgrade succeeds, the Upgrade succeeds image is displayed.

Page 12: Version: ZStack 3.8.0 Issue: V3.8 ZStack V3... · 2020. 4. 3. · Upgrade Tutorial / 3 Management Node Upgrade Issue: V3.8.0 5 • During the upgrade, the proxy server of ZStack will

Upgrade Tutorial / 3 Management Node Upgrade

Issue: V3.8.0 9

Figure 3-3: Upgrade succeeds

Page 13: Version: ZStack 3.8.0 Issue: V3.8 ZStack V3... · 2020. 4. 3. · Upgrade Tutorial / 3 Management Node Upgrade Issue: V3.8.0 5 • During the upgrade, the proxy server of ZStack will

Upgrade Tutorial / Glossary

10 Issue: V3.8.0

Glossary

ZoneA zone is a logical group of resources such as clusters, L2 networks, and primary storages. Zone

is the largest resource scope defined in ZStack.

ClusterA cluster is a logical group of analogy hosts (compute nodes). Hosts in the same cluster must be

installed with the same operating system, have the same network configuration, and be able to

access the same primary storage. In a real data center, a cluster usually maps to a rack.

Management NodeA management node is a host with operating system installed to provide UI management and

cloud platform deployment.

Compute NodeA compute node is a physical server (also known as a host) that provides VM instances with

compute, network, and storage resources.

Primary StorageA primary storage is a storage server used to store disk files in VM instances. Local storage, NFS,

Ceph, Shared Mount Point, and SharedBlock are supported.

Backup StorageA backup storage is a storage server used to store image template files. ImageStore, SFTP

(Community Edition), and Ceph are supported. We recommend that you deploy backup storage

separately.

ImageStoreImageStore is a type of backup storage. You can use ImageStore to create images for VM

instances that are in the running state and manage image version updates and release.

ImageStore allows you quickly upload, download, export images, and create image snapshots as

needed.

Page 14: Version: ZStack 3.8.0 Issue: V3.8 ZStack V3... · 2020. 4. 3. · Upgrade Tutorial / 3 Management Node Upgrade Issue: V3.8.0 5 • During the upgrade, the proxy server of ZStack will

Upgrade Tutorial / Glossary

Issue: V3.8.0 11

VM InstanceA VM instance is a virtual machine instance running on a host. A VM instance has its own IP

address to access public network and run application services.

ImageAn image is an image template used by a VM instance or volume. Image templates include

system volume images and data volume images.

VolumeA volume can either be a data volume or a root volume. A volume provides storage to a VM

instance. A shared volume can be attached to one or more VM instances.

Instance OfferingAn instance offering is a specification of the VM instance CPU and memory, and defines the host

allocator strategy, disk bandwidth, and network bandwidth.

Disk OfferingA disk offering is a specification of a volume, which defines the size of a volume and how the

volume will be created.

L2 NetworkAn L2 network is a layer 2 broadcast domain used for layer 2 isolation. Generally, L2 networks are

identified by names of devices on the physical network.

L3 NetworkAn L3 network is a collection of network configurations for VM instances, including the IP range,

gateway, and DNS.

Public NetworkA public network is generally allocated with a public IP address by Network Information Center

(NIC) and can be connected to IP addresses on the Internet.

Private NetworkA private network is the internal network that can be connected and accessed by VM instances.

Page 15: Version: ZStack 3.8.0 Issue: V3.8 ZStack V3... · 2020. 4. 3. · Upgrade Tutorial / 3 Management Node Upgrade Issue: V3.8.0 5 • During the upgrade, the proxy server of ZStack will

Upgrade Tutorial / Glossary

12 Issue: V3.8.0

L2NoVlanNetworkL2NoVlanNetwork is a network type for creating an L2 network. If L2NoVlanNetwork is selected,

VLAN settings are not used for host connection.

L2VlanNetworkL2VlanNetwork is a network type for creating an L2 network. If L2VlanNetwork is selected, VLAN

settings are used for host connection and need to be configured on the corresponding switches in

advance.

VXLAN PoolA VXLAN pool is an underlay network in VXLAN. You can create multiple VXLAN overlay

networks (VXLAN) in a VXLAN pool. The overlay networks can operate on the same underlay

network device.

VXLANA VXLAN network is a L2 network encapsulated by using the VXLAN protocol. A VXLAN network

belongs to a VXLAN pool. Different VXLAN networks are isolated from each other on the L2

network.

vRouterA vRouter is a custom Linux VM instance that provides various network services.

Security GroupA security group provides L3 network firewall control over the VM instances. It can be used to set

different security rules to filter IP addresses, network packet types, and the traffic flow of network

packets.

EIPAn elastic IP (EIP) address is a method to access a private network through a public network.

SnapshotA snapshot is a point-in-time capture of data status in a disk. A snapshot can be either an

automatic snapshot or a manual snapshot.