@@ -11,14 +11,14 @@ To install the CrunchyDB HA Cluster in the **dev** namespace, run the following
1111To perform an adhoc backup of the database run the following command.
1212
1313``` bash
14- oc annotate -n 9b301c-test postgrescluster postgres-cluster \
14+ oc annotate -n 9b301c-prod postgrescluster crunchy \
1515 postgres-operator.crunchydata.com/pgbackrest-backup=" $( date ' +%F_%H:%M:%S' ) "
1616```
1717
1818Subsequent runs will require the ` --overwrite ` attribute.
1919
2020``` bash
21- oc annotate -n 9b301c-test postgrescluster postgres-cluster --overwrite \
21+ oc annotate -n 9b301c-prod postgrescluster crunchy --overwrite \
2222 postgres-operator.crunchydata.com/pgbackrest-backup=" $( date ' +%F_%H:%M:%S' ) "
2323```
2424
@@ -56,7 +56,7 @@ oc kustomize openshift/kustomize/postgres/crunchy/overlays/dev | oc apply -f -
5656You will need to wait and confirm the backup has been completed, as this is just a request for it do it when it can.
5757
5858``` bash
59- oc annotate -n 9b301c-test postgrescluster postgres-cluster \
59+ oc annotate -n 9b301c-test postgrescluster crunchy \
6060 postgres-operator.crunchydata.com/pgbackrest-backup=" $( date ' +%F_%H:%M:%S' ) "
6161```
6262
@@ -79,32 +79,32 @@ Link the cluster to the update.
7979
8080` ` ` bash
8181# Annotate the cluster
82- oc -n 9b301c-dev annotate postgrescluster crunchy postgres-operator.crunchydata.com/allow-upgrade="crunchy-upgrade"
82+ oc -n 9b301c-prod annotate postgrescluster crunchy postgres-operator.crunchydata.com/allow-upgrade="crunchy-upgrade"
8383```
8484
8585Shutdown the cluster.
8686
8787``` bash
88- oc patch postgrescluster/crunchy -n 9b301c-dev --type merge --patch ' {"spec":{"shutdown": true}}'
88+ oc patch postgrescluster/crunchy -n 9b301c-prod --type merge --patch ' {"spec":{"shutdown": true}}'
8989```
9090
9191### Step 6: Watch and Wait
9292
9393Check on status.
9494
9595``` bash
96- oc describe pgupgrade -n 9b301c-dev
96+ oc describe pgupgrade -n 9b301c-prod
9797```
9898
9999### Step 7: Restart
100100
101101Update ` PostgresCluster ` object with ` spec.postgresVersion: 15 ` .
102102
103103``` bash
104- oc patch postgrescluster/crunchy -n 9b301c-dev --type merge --patch ' {"spec":{"postgresVersion": 15}}'
104+ oc patch postgrescluster/crunchy -n 9b301c-prod --type merge --patch ' {"spec":{"postgresVersion": 15}}'
105105
106106# Start up again
107- oc patch postgrescluster/crunchy -n 9b301c-dev --type merge --patch ' {"spec":{"shutdown": false}}'
107+ oc patch postgrescluster/crunchy -n 9b301c-prod --type merge --patch ' {"spec":{"shutdown": false}}'
108108```
109109
110110### Other Commands
@@ -114,3 +114,9 @@ If you need to restart.
114114``` bash
115115oc patch postgrescluster/crunchy -n 9b301c-dev --type merge --patch ' {"spec":{"metadata":{"annotations":{"restarted":"' " $( date) " ' "}}}}'
116116```
117+
118+ ### Restore
119+
120+ ``` bash
121+ oc annotate -n 9b301c-dev postgrescluster crunchy --overwrite postgres-operator.crunchydata.com/pgbackrest-restore=" $( date) "
122+ ```
0 commit comments