Creating and Maintaining Disaster Recovery Plans
Each DR plan defines the steps to perform on Private Cloud Appliance cloud resources when a DR operation is executed: failover, switchover, or postfailover.
Each DR configuration has an associated DR plan file. This file can contain multiple DR plans, each identified by a unique name assigned by the administrator during creation. The DR plan file is stored in JSON format in the directory /mnt/dr_metadata
on the standby rack.
Creating a DR Plan
The DR service provides default plans for each standard operation. You create them with a simple command to get started. If necessary, you can customize the plan steps afterward.
- Using the Service CLI
-
-
Look up the ID of the DR configuration for which you want to create a DR plan (
drGetConfigs
). -
Create a default DR plan with the
create DrPlan
command.Typically, a DR configuration has associated DR plans for each operation type. In this example, plans are created for failover, switchover, and postfailover.
PCA-ADMIN> create DrPlan drConfigId=6e797d8b-7245-4d49-8e68-bf67f2d53041 operation=SWITCHOVER planName=sw1 JobId: eae66f69-7b99-420e-b324-7d8964b2202b Data: DrPlan id: 6e797d8b-7245-4d49-8e68-bf67f2d53041::sw1. Successfully started job for DR Plan Create for config_id 6e797d8b-7245-4d49-8e68-bf67f2d53041 PCA-ADMIN> create DrPlan drConfigId=6e797d8b-7245-4d49-8e68-bf67f2d53041 operation=FAILOVER planName=fo1 PCA-ADMIN> create DrPlan drConfigId=6e797d8b-7245-4d49-8e68-bf67f2d53041 operation=POSTFAILOVER planName=pfo1
-
Use the job ID to check the status of the operation you started.
PCA-ADMIN> show Job id=eae66f69-7b99-420e-b324-7d8964b2202b Data: Id = eae66f69-7b99-420e-b324-7d8964b2202b Type = Job Associated Work Request Id = ec0f39df-6256-4c4c-a839-0d00a8f326dc Done = true Name = CREATE_TYPE Progress Message = DrPlan id: 6e797d8b-7245-4d49-8e68-bf67f2d53041::sw1. Successfully created [sw1] plan on STANDBY for DR operation [switchover] for config [6e797d8b-7245-4d49-8e68-bf67f2d53041] Run State = Succeeded Transcript = Created job CREATE_TYPE Username = admin WorkItemIds 1 = id:5ca6d187-e01a-40e2-bc97-3193a9a88742 type:WorkItem name:
-
To display a list of existing DR plans for a DR configuration, use the
drListPlan
command.PCA-ADMIN> drListPlan drConfigId=6e797d8b-7245-4d49-8e68-bf67f2d53041 Data: id Plan Name Operation -- --------- --------- 6e797d8b-7245-4d49-8e68-bf67f2d53041::sw1 sw1 switchover 6e797d8b-7245-4d49-8e68-bf67f2d53041::fo1 fo1 failover 6e797d8b-7245-4d49-8e68-bf67f2d53041::pfo1 pfo1 postfailover
-
To display the status and details of a DR plan, use the
show DrPlan
command.PCA-ADMIN> show DrPlan id=6e797d8b-7245-4d49-8e68-bf67f2d53041::sw1 Data: Id = 6e797d8b-7245-4d49-8e68-bf67f2d53041::sw1 Type = DrPlan Plan Id = 6e797d8b-7245-4d49-8e68-bf67f2d53041::sw1 Plan Name = sw1 Config Id = 6e797d8b-7245-4d49-8e68-bf67f2d53041 Operation = switchover Steps 1 - Step Id = 6e797d8b-7245-4d49-8e68-bf67f2d53041::sw1::precheck Steps 1 - Step Name = PRECHECK Steps 1 - Enabled = true Steps 1 - Last Status = norun Steps 1 - Command = None Steps 1 - Check Only = true Steps 2 - Step Id = 6e797d8b-7245-4d49-8e68-bf67f2d53041::sw1::role_reversal_precheck Steps 2 - Step Name = ROLE_REVERSAL_PRECHECK Steps 2 - Enabled = true Steps 2 - Last Status = norun Steps 2 - Command = None Steps 2 - Check Only = true Steps 3 - Step Id = 6e797d8b-7245-4d49-8e68-bf67f2d53041::sw1::stop_primary Steps 3 - Step Name = STOP_PRIMARY Steps 3 - Enabled = true Steps 3 - Last Status = norun Steps 3 - Command = None Steps 3 - Check Only = false Steps 4 - Step Id = 6e797d8b-7245-4d49-8e68-bf67f2d53041::sw1::role_reversal Steps 4 - Step Name = ROLE_REVERSAL Steps 4 - Enabled = true Steps 4 - Last Status = norun Steps 4 - Command = None Steps 4 - Check Only = false Steps 5 - Step Id = 6e797d8b-7245-4d49-8e68-bf67f2d53041::sw1::start_standby Steps 5 - Step Name = START_STANDBY Steps 5 - Enabled = true Steps 5 - Last Status = norun Steps 5 - Command = None Steps 5 - Check Only = false Steps 6 - Step Id = 6e797d8b-7245-4d49-8e68-bf67f2d53041::sw1::cleanup_primary Steps 6 - Step Name = CLEANUP_PRIMARY Steps 6 - Enabled = true Steps 6 - Last Status = norun Steps 6 - Command = None Steps 6 - Check Only = false Steps 7 - Step Id = 6e797d8b-7245-4d49-8e68-bf67f2d53041::sw1::post_config Steps 7 - Step Name = POST_CONFIG Steps 7 - Enabled = true Steps 7 - Last Status = norun Steps 7 - Command = None Steps 7 - Check Only = false
-
- Using the Service Web UI
-
-
Under Disaster Recovery Service, open the DR Configurations page. In the table, click the configuration to which you want to add a DR plan. The DR Configuration detail page appears.
-
In the Resources section, click Plans.
On the right hand side of the Plans box, click Add Plan.
-
In the Create DR Plan window, enter the following information in the respective fields:
-
Plan Name: Enter a name for this DR plan.
-
Operation: Select a standard operation: switchover, failover, postfailover.
-
Steps: Leave blank if you want the default steps for the selected operation. Otherwise, specify the steps to add to the DR plan. The options are: 'precheck', 'role_reversal_precheck', 'stop_primary', 'role_reversal', 'start_standby', 'cleanup_primary', 'post_config'.
-
Dr Plan Data File: Used for migrating first-generation DR plans. Leave blank.
-
Configurations To Migrate: Used for migrating first-generation DR plans. Leave blank.
-
-
Click Create DR Plan. A DR job is started. When it completes successfully, the DR plan appears in the resources table.
To track progress, under Disaster Recovery Service, select Jobs. The Jobs table reports the status of each job. Click a record in the table to display the job details.
-
Repeat these steps to add all the required DR plans.
-
Optionally, click a DR plan name to display its detail page.
-
Changing a DR Plan
A DR plan has a complex structure with many parameters, which makes it difficult to update from the command line in particular. Instead, you can change the individual steps that make up the DR plan. See Customizing the Steps in a Disaster Recovery Plan.
Deleting a DR Plan
You can remove a DR plan if it is no longer required. To delete all plans associated with a DR configuration at once, use the command drDeleteAllPlans
.
- Using the Service CLI
-
-
Look up the ID of the DR plan you want to delete (
drListPlan
). -
Remove the selected DR plan with the
delete DrPlan
command.PCA-ADMIN> delete DrPlan id=6e797d8b-7245-4d49-8e68-bf67f2d53041::fo2 JobId: 603d480f-1e0f-4229-b596-aaaf8588e682 Data: DrPlan id: 6e797d8b-7245-4d49-8e68-bf67f2d53041::fo2. Successfully started job for DR Plan delete for config_id 6e797d8b-7245-4d49-8e68-bf67f2d53041
-
Use the job ID to check the status of the operation you started.
PCA-ADMIN> show Job id=603d480f-1e0f-4229-b596-aaaf8588e682 Data: Id = 603d480f-1e0f-4229-b596-aaaf8588e682 Type = Job Associated Work Request Id = 391a0799-235a-4b26-aa99-4b5dd14ba19a Done = true Name = DELETE_TYPE Progress Message = DrPlan id: 6e797d8b-7245-4d49-8e68-bf67f2d53041::fo2. Successfully deleted [fo2] plan on STANDBY for config [6e797d8b-7245-4d49-8e68-bf67f2d53041] Run State = Succeeded Transcript = Created job DELETE_TYPE Username = admin WorkItemIds 1 = id:86d0bd13-5f9c-4513-9404-60d8980b2243 type:WorkItem name:
-
- Using the Service Web UI
-
-
Under Disaster Recovery Service, open the DR Configurations page. In the table, click the configuration for which you want to delete a DR plan. The DR Configuration detail page appears.
-
In the Resources section, click Plans. All existing DR plans are displayed in the table.
-
In the Actions column, open the quick menu (3 dots) and click Delete.
Alternatively, click the DR plan name to display its detail page. In the top-right corner, click Delete.
-
When prompted, click Confirm. A DR job is started. When it completes successfully, the DR plan is removed from the table.
To track progress, under Disaster Recovery Service, select Jobs. The Jobs table reports the status of each job. Click a record in the table to display the job details.
-
Repeat until all obsolete DR plans have been removed.
-
Deleting All DR Plans
Instead of deleting DR plans one by one, you can delete all plans associated with a DR configuration at once.
- Using the Service CLI
-
-
Look up the ID of the DR configuration for which you want to delete all plans (
drGetConfigs
). -
Remove the selected DR plan with the
drdeleteallPlans
command.PCA-ADMIN> drdeleteallPlans drConfigId=6e797d8b-7245-4d49-8e68-bf67f2d53041 JobId: b595dd62-8046-4ca7-90a0-dcbbf084e663 Data: DrPlan id: 6e797d8b-7245-4d49-8e68-bf67f2d53041::all_plans. Successfully started job for DR Plan delete for config_id 6e797d8b-7245-4d49-8e68-bf67f2d53041
-
Use the job ID to check the status of the operation you started.
PCA-ADMIN> show Job id=b595dd62-8046-4ca7-90a0-dcbbf084e663 Data: Id = b595dd62-8046-4ca7-90a0-dcbbf084e663 Type = Job Associated Work Request Id = d7cfb184-4e38-469d-b189-bb809386f5d4 Done = true Name = DELETE_TYPE Progress Message = DrPlan id: 6e797d8b-7245-4d49-8e68-bf67f2d53041::all_plans. Successfully deleted [all_plans] plan on STANDBY for config [6e797d8b-7245-4d49-8e68-bf67f2d53041] Run State = Succeeded Transcript = Created job DELETE_TYPE Username = admin WorkItemIds 1 = id:6cfec1c9-4a72-492d-a414-38bf4df6cf3a type:WorkItem name:
-
- Using the Service Web UI
-
-
Under Disaster Recovery Service, open the DR Configurations page. In the table, click the configuration for which you want to delete a DR plan. The DR Configuration detail page appears.
-
In the Resources section, click Plans. All existing DR plans are displayed in the table.
Verify that all plans in the table should be deleted.
-
In the top-right corner, select Controls, then click Delete All Plans.
-
When prompted, click Confirm. A DR job is started. When it completes successfully, all DR plan are removed from the table.
To track progress, under Disaster Recovery Service, select Jobs. The Jobs table reports the status of each job. Click a record in the table to display the job details.
-