Offline Upgrade of Operations Management Module¶
This page provides instructions on how to install or upgrade the Operations Management module after downloading it from the Download Center.
Info
The term gmagpie
used in the following commands or scripts refers to the internal development codename for the Operations Management module.
Loading Image from the Installation Package¶
You can load the image using either of the following methods. It is recommended to choose the chart-syncer method when an registry already exists in the environment, as it is more efficient and convenient.
Synchronize Images to Registry using chart-syncer¶
-
Create load-image.yaml .
Note
All parameters in this YAML file are mandatory. You need a private registry and modify the relevant configurations accordingly.
load-image.yamlsource: intermediateBundlesPath: gmagpie-offline # (1)! target: containerRegistry: 10.16.10.111 # (2)! containerRepository: release.daocloud.io/gmagpie # (3)! repo: kind: HARBOR # (4)! url: http://10.16.10.111/chartrepo/release.daocloud.io # (5)! auth: username: "admin" # (6)! password: "Harbor12345" # (7)! containers: auth: username: "admin" # (8)! password: "Harbor12345" # (9)!
- Use the relative path to run the
charts-syncer
command, not the relative path - Modify it to your registry URL.
- Modify it to your registry.
- It can also be any other supported Helm Chart repository category.
- Need to be changed to chart repo url
- Your registry username.
- Your registry password.
- Your registry username.
- Your registry password.
If a chart repo is not installed in the current environment, chart-syncer also supports exporting the chart as a tgz file and storing it in the specified path.
load-image.yamlsource: intermediateBundlesPath: gmagpie-offline # (1)! target: containerRegistry: 10.16.10.111 # (2)! containerRepository: release.daocloud.io/gmagpie # (3)! repo: kind: LOCAL path: ./local-repo # (4)! containers: auth: username: "admin" # (5)! password: "Harbor12345" # (6)!
- Use the relative path to run the
charts-syncer
command, not the relative path between this YAML file and the offline package. - Modify it to your registry URL.
- Modify it to your registry.
- Local path of the chart.
- Your registry username.
- Your registry password.
- Use the relative path to run the
-
Run the command to synchronize images.
If x509 certificate error occurs, please add the --insecure flag.
Loading directly with Docker or containerd¶
Unpack and load the image file.
-
Unpack the tar archive.
After a successful unpacking, you will obtain 3 files:
- hints.yaml
- images.tar
- original-chart
-
Load the image from the local source into Docker or containerd.
Note
Each node needs to perform the image loading operation with Docker or containerd. After loading is complete, it is necessary to tag the image to keep the Registry and Repository consistent with the installation.
Upgrade¶
There are two ways to upgrade. You can choose the corresponding upgrade method based on the preconditions:
Note
When upgrading from v0.1.x (or lower) to v0.2.0 (or higher), database connection parameters need to be modified.
Example of modifying database connection parameters:
USER-SUPPLIED VALUES:
global:
database:
host: 127.0.0.1
port: 3306
dbname: gmagpie
password: passowrd
user: gmagpie
Modified to:
USER-SUPPLIED VALUES:
global:
storage:
gmagpie:
- driver: mysql
accessType: readwrite
dsn: {global.database.apiserver.user}:{global.database.apiserver.password}@tcp({global.database.host}:{global.database.port})/{global.database.apiserver.dbname}?charset=utf8mb4&multiStatements=true&parseTime=true
-
Check if the Operations Management Helm repository exists.
If the result is empty or shows the following prompt, proceed to the next step; otherwise, skip the next step.
-
Add the Operations Management Helm repository.
-
Update the Operations Management Helm repository.
- If the Helm version is too low, it may result in failure. If this happens, please try executing helm update repo .
-
Choose the version of Operations Management that you would like to install (it is recommended to install the latest version).
-
Back up the
--set
parameters.Before upgrading the Operations Management version, it is recommended to run the following command to back up the
--set
parameters of the old version. -
Run
helm upgrade
.Before upgrading, it is recommended to replace the global.imageRegistry field in the bak.yaml file with the address of the registry you are currently using.
-
Back up the
--set
parameters.Before upgrading the Operations Management version, it is recommended to run the following command to back up the
--set
parameters of the old version. -
Run
helm upgrade
.It is recommended to replace the global.imageRegistry field in the bak.yaml file with the address of the registry you are currently using before performing the upgrade.