Important
|
If your {productname} deployment is upgrading from one y-stream to the next, for example, from 3.8.10 → 3.8.11, you must not switch the upgrade channel from |
When updating {productname} 3.8 → 3.9, the Operator automatically upgrades the existing PostgreSQL databases for Clair and {productname} from version 10 to version 13.
Important
|
|
You can update {productname} and the {productname} and Clair PostgreSQL databases on {ocp} by using the Web Console UI, or by using the CLI.
Updating {productname} and the {productname} and Clair PostgreSQL databases using the {ocp} web console
Use the following procedure to update {productname} and the {productname} and Clair PostgreSQL databases using the {ocp} web console.
Important
|
|
-
You have installed {productname} 3.6, 3.7, or 3.8 on {ocp}.
-
100 GB of free, additional storage.
During the upgrade process, additional persistent volume claims (PVCs) are provisioned to store the migrated data. This helps prevent a destructive operation on user data. The upgrade process rolls out PVCs for 50 GB for both the {productname} database upgrade, and the Clair database upgrade.
-
Optional. Back up your old PVCs from PostgreSQL 10 by setting
POSTGRES_UPGRADE_DELETE_BACKUP
tofalse
yourquay-operator
Subscription
object. For example:apiVersion: operators.coreos.com/v1alpha1 kind: Subscription metadata: name: quay-operator namespace: quay-enterprise spec: channel: stable-3.8 name: quay-operator source: redhat-operators sourceNamespace: openshift-marketplace config: env: - name: POSTGRES_UPGRADE_DELETE_BACKUP (1) value: "false"
-
When set to
true
, removes old PVCs after upgrading.
-
-
In the {ocp} Web Console, navigate to Operators → Installed Operators.
-
Click on the {productname} Operator.
-
Navigate to the Subscription tab.
-
Under Subscription details click Update channel.
-
Select stable-3.9 and save the changes.
-
Check the progress of the new installation under Upgrade status. Wait until the upgrade status changes to 1 installed before proceeding.
-
In your {ocp} cluster, navigate to Workloads → Pods. Existing pods should be terminated, or in the process of being terminated.
-
Wait for the following pods, which are responsible for upgrading the database and alembic migration of existing data, to spin up:
clair-postgres-upgrade
,quay-postgres-upgrade
, andquay-app-upgrade
. -
After the
clair-postgres-upgrade
,quay-postgres-upgrade
, andquay-app-upgrade
pods are marked as Completed, the remaining pods for your {productname} deployment spin up. This takes approximately ten minutes. -
Verify that the
quay-database
uses thepostgresql-13
image andclair-postgres
pods now use thepostgresql-15
image. -
After the
quay-app
pod is marked as Running, you can reach your {productname} registry.
Use the following procedure to update {productname} and the {productname} and Clair PostgreSQL databases using the command-line interface (CLI).
Important
|
|
-
You have installed {productname} 3.6, 3.7, or 3.8 on {ocp}.
-
100 GB of free, additional storage.
During the upgrade process, additional persistent volume claims (PVCs) are provisioned to store the migrated data. This helps prevent a destructive operation on user data. The upgrade process rolls out PVCs for 50 GB for both the {productname} database upgrade, and the Clair database upgrade.
-
Retrieve your
quay-operator
configuration file by entering the followingoc get
command:$ oc get subscription quay-operator -n quay-enterprise -o yaml > quay-operator.yaml
-
Retrieve the latest version of the {productname} Operator and its channel by entering the following command:
oc get packagemanifests quay-operator \ -o jsonpath='{range .status.channels[*]}{@.currentCSV} {@.name}{"\n"}{end}' \ | awk '{print "STARTING_CSV=" $1 " CHANNEL=" $2 }' \ | sort -nr \ | head -1
Example outputSTARTING_CSV=quay-operator.v3.9.0 CHANNEL=stable-3.9
-
Using the output from the previous command, update your
Subscription
custom resource for the {productname} Operator and save it asquay-operator.yaml
. For example:apiVersion: operators.coreos.com/v1alpha1 kind: Subscription metadata: name: quay-operator namespace: quay-enterprise spec: channel: stable-3.9 (1) name: quay-operator source: redhat-operators sourceNamespace: openshift-marketplace config: env: - name: POSTGRES_UPGRADE_DELETE_BACKUP (2) value: "false"
-
Specify the value you obtained in the previous step for the
spec.channel
parameter. -
Optional. Back up your old PVCs from PostgreSQL 10 by setting
POSTGRES_UPGRADE_DELETE_BACKUP
tofalse
yourquay-operator
Subscription
object.
-
-
Enter the following command to apply the configuration:
$ oc apply -f quay-operator.yaml
Example outputsubscription.operators.coreos.com/quay-operator created