Upgrade PX-Backup
This topic provides procedures for migrating from PX-Backup version 1.2.x to 2.x.x, and to upgrade the PX-Backup 2.x.x version to the latest version.
You can upgrade from 1.2.x versions by applying three Helm charts to migrate the PX-Backup, License Server, and Monitoring service components independently:
- px-backup
- px-monitor
- px-license-sever
To upgrade from 2.x.x, you can use just the px-central
chart to upgrade all three components.
Upgrade from 2.x.x to 2.1.1
To upgrade from PX-Backup version 2.x.x to 2.1.1:
Update your Helm repository:
helm repo update
Retrieve all custom values you used during the PX-Backup installation. Enter the following
helm get values
command to generate a YAML file, replacing the<namespace>
and<release-name>
parameters to match your environment:helm get values --namespace <docs-namespace> <release-name> -o yaml > values.yaml
Delete the post install hook job.
kubectl delete job pxcentral-post-install-hook --namespace <namespace>
Run the
helm upgrade
command to upgrade PX-Backup, using the-f
flag to pass the customvalues.yaml
file you generated above and replacing<release-name>
,<repo-name>
, and<namespace>
parameters to match your environment. Replace the<current-admin-password>
parameter with the current administrator password.helm upgrade <release-name> <repo-name>/px-central --namespace <namespace> --set oidc.centralOIDC.defaultPassword=<current-admin-password> -f values.yaml
Consider you installed or upgraded an earlier PX-Backup version using the values.yaml
, which you either:
- generated from the Spec Gen wizard (or)
- cloned from the PX-Backup Helm repository
In this case, you must specify the changes you made in the earlier version values.yaml
in the new values.yaml
that you use for installing or upgrading to PX-Backup 2.1.1.
For example:
In the existing values.yaml
, if the persistentStorage.storageClassName
parameter is set with the value portworx-sc
, then you must the set the same portworx-sc
value in the new values.yaml
.
Access permissions in PX-Backup 2.x.x
The permissions available to administrators from the PX-Backup 2.x.x versions to access resources are:
- Can view and backup clusters that you added.
- Can view all user created backups in the Backup page.
- Can view all PX-Backup Security objects such as cloud credentials, backup locations, schedule policies, and backup rules of all users.
- Cannot view all non-PX-Backup Security objects.
The access permissions available to a user in case of backup sync are:
- If a user is the owner of a bucket, then the Backups page lists backups of all users who used that bucket.
- If a user is a collaborator, then the user can view own backups only.
Migrate from 1.2.x to 2.x.x
To migrate from PX-Backup 1.2.x versions to 2.x.x:
Download the
migration.sh
file.curl https://raw.githubusercontent.com/portworx/helm/master/single_chart_migration/migration.sh -o migration.sh
Change the
migration.sh
file permissions to make it executable.chmod +x migration.sh
Update the Helm repository.
helm repo update
Search for the Portworx repository.
helm search repo portworx
Get the namespace where the PX-Backup components are installed.
helm ls -A | grep "px-backup-[0-9].[0-9].[0-9]" | awk '{print $2}'
Run the
migration.sh
file to upgrade to PX-Backup 2.x.x../migration.sh --namespace <namespace> --helmrepo <helm repo name> --admin-password <current-admin-user-password>
If you are in air-gapped environment, then follow the steps below to upgrade PX-Backup from the prior versions to 2.x.x:
Clone the Portworx helm repository.
git clone https://github.com/portworx/helm.git
Make the
migration.sh
an executable file.chmod +x /single_chart_migration/migration.sh
Get the namespace where the PX-Backup components are installed.
helm ls -A | grep "px-backup-[0-9].[0-9].[0-9]" | awk '{print $2}'
Modify the
px-backup/values.yaml
file matching your internal registry, repository, and image pull secret parameters. Pass the modifiedvalues.yaml
file with the--helm-values-file
option.Run the
migration.sh
file to upgrade to PX-Backup 2.x.x../migration.sh --namespace <namespace> --helmrepo <current-directory/charts> --admin-password <current-admin-user- password> --air-gapped --helm-values-file <values.yaml>