Failover disaster recovery protected discovered application
Before you begin
- Ensure that the application namespace is created in both managed clusters (for example,
busybox-discovered).
About this task
This section guides you on how to failover a discovered application which is disaster recovery protected.
Procedure
- In the RHACM console, navigate to Disaster Recovery > Protected applications tab.
- At the end of the application row, click on the Actions menu and choose to initiate Failover.
- In the Failover application modal window, review the status of the application and the target cluster.
- Click Initiate. Wait for the
Failoverprocess to complete. - Verify that the busybox application is running on the Secondary managed
cluster.
oc get pods,pvc -n busybox-discoveredNAME READY STATUS RESTARTS AGE pod/busybox-796fccbb95-qmxjf 1/1 Running 0 2m46s NAME STATUS VOLUME CAPACITY ACCESS MODES STORAGECLASS VOLUMEATTRIBUTESCLASS AGE persistentvolumeclaim/busybox-pvc Bound pvc-b20e4129-902d-47c7-b962-040ad64130c4 1Gi RWO ocs-storagecluster-ceph-rbd <unset> 2m57s NAME AGE VOLUMEREPLICATIONCLASS PVCNAME DESIREDSTATE CURRENTSTATE volumereplication.replication.storage.openshift.io/busybox-pvc 2m45s rbd-volumereplicationclass-1625360775 busybox-pvc primary Primary - Check the progression status of Failover until the result
is
WaitOnUserToCleanup. The DRPC name can be identified by the unique Name configured in prior steps (for example,busybox-rbd).oc get drpc {drpc_name} -n openshift-dr-ops -o jsonpath='{.status.progression}{"\n"}'WaitOnUserToCleanUp - Remove the
busyboxapplication from the Primary managed cluster to complete the Failover process.- Navigate to the Protected applications tab. You will see a message to remove the application.
- Navigate to the cloned repository for
busyboxand run the following commands on the Primary managed cluster where you failed over from. Use the same directory that was used to create the application (for example,odr-regional-rbd).cd ~/ocm-ramen-samples/ git branch* mainoc delete -k workloads/deployment/odr-regional-rbd -n busybox-discoveredpersistentvolumeclaim "busybox-pvc" deleted deployment.apps "busybox" deleted
- After deleting the application, navigate to the Protected applications tab and verify that the busybox resources are both in Healthy status.