Upgrade DCE 5.0 Components¶
The upgrade of DCE 5.0 components involves upgrading the product modules and the infrastructure modules of DCE 5.0.
-
DCE 5.0 consists of several modules, including container management, global management, insight, and more. These are primarily defined in the
components
section of the manifest.yaml file. -
The components specific to the infrastructure modules of DCE 5.0 are defined in the
infrastructures
section of the manifest.yaml file.
Warning
-
Since DCE 5.0 includes a wide range of product modules, it's advisable to upgrade the DCE 5.0 components one version at a time using the installer, rather than jumping across multiple versions.
-
Keep in mind that upgrading the DCE 5.0 components could overwrite your business data, so be sure to back up your data before proceeding!
Prerequisites¶
- You need to have a DCE 5.0 cluster environment. Refer to Offline Deployment of DCE 5.0 Enterprise.
- Ensure that your bootstrap machine is still alive.
- Confirm the version you want to upgrade to. See Release Notes.
Offline Upgrade Steps¶
This demonstration shows how to upgrade from v0.8.0 to v0.9.0. Currently, when upgrading from a lower version to v0.9.0, it is necessary to upgrade both the product functionality modules and the infrastructure modules of DCE 5.0 in order to make use of the high availability feature of the istio-gateway
component.
Step 1: Download the v0.9.0 Offline Package¶
You can download the latest version from the Download Center.
CPU Architecture | Version | Download Link |
---|---|---|
AMD64 | v0.9.0 | Download Link |
ARM64 | v0.9.0 | Download Link |
After downloading, extract the offline package. For example, for the AMD64 architecture:
Step 2: Configure clusterConfig.yaml¶
Note
- Make sure that the cluster configuration file is consistent with the parameters used during installation.
- Currently, only the
builtin
method ofimagesAndCharts
has been tested.
The file is located under the offline/sample
directory after extracting the offline package. Refer to the following sample configuration:
apiVersion: provision.daocloud.io/v1alpha3
kind: ClusterConfig
metadata:
spec:
clusterName: my-cluster
loadBalancer:
type: metallb
istioGatewayVip: 172.30.**.**/32
insightVip: 172.30.**.**/32
masterNodes:
- nodeName: "g-master1"
ip: 172.30.**.**
ansibleUser: "root"
ansiblePass: "*****"
workerNodes:
- nodeName: "g-worker1"
ip: 172.30.**.**
ansibleUser: "root"
ansiblePass: "*****"
- nodeName: "g-worker2"
ip: 172.30.**.**
ansibleUser: "root"
ansiblePass: "*****"
fullPackagePath: "/home/installer/offline"
osRepos:
type: builtin
isoPath: "/home/installer/CentOS-7-x86_64-DVD-2207-02.iso"
osPackagePath: "/home/installer/os-pkgs-centos7-v0.4.4.tar.gz"
imagesAndCharts:
type: builtin
addonPackage:
binaries:
type: builtin # (1)!
official-service
(if omitted or empty),builtin
, orexternal
Step 3: Configure manifest.yaml (Optional)¶
The file is located under the offline/sample
directory after extracting the offline package.
Configure DCE 5.0 Functionality Modules¶
The components specific to modules of DCE 5.0 are defined in the components
section of the manifest.yaml file. If you don't want to upgrade certain product components, you can disable them. For example, if you want to skip the upgrade for Kpanda (container management), use the following configuration:
Configure DCE 5.0 Infrastructure Modules¶
The components specific to the infrastructure modules of DCE 5.0 are defined in the infrastructures
section of the manifest.yaml file. For example, the following configuration is for the hwameiStor
component in the infrastructure module:
Note
Currently, only the upgrade of product components that are already installed in the current environment is supported. Non-existent components will be skipped during the upgrade process.
Step 4: Start the Upgrade¶
Upgrade DCE 5.0 Functionality Modules¶
Run the upgrade command:
./offline/dce5-installer cluster-create -c ./offline/sample/clusterConfig.yaml -m ./offline/sample/manifest.yaml --upgrade gproduct
Upgrade DCE 5.0 Infrastructure Modules¶
Run the upgrade command:
./offline/dce5-installer cluster-create -c ./offline/sample/clusterConfig.yaml -m ./offline/sample/manifest.yaml --upgrade infrastructure
Explanation of upgrade parameters:
install-app
orcluster-create
: Represents the installation mode type of DCE 5.0. If the initial environment was installed usingcluster-create
, use this command for the upgrade as well.--upgrade
can be abbreviated as-u
, currently supporting upgrades for:- DCE 5.0 product modules (gproduct)
- Infrastructure modules (infrastructure)
- Local storage modules (hwameistor)
- Middleware modules (middleware)
- To upgrade both the product functionality modules and the infrastructure modules together, specify the parameter
--upgrade infrastructures,gproduct
. - The installer v0.12.0 introduces support for the
--multi-arch
parameter. This parameter is mainly used when there are multiple architecture images in the current environment. By adding this parameter during the upgrade process, it prevents overwriting of existing multi-architecture images.