5 Performing Oracle Site Guard Operations
An Oracle Site Guard operation plan specifies the action steps and their order of execution. Learn how to create, execute, and monitor Oracle Site Guard operation plans.
Overview
An Oracle Site Guard operation plans specifies the steps executed during a disaster recovery. This workflow allows step execution in series or in parallel.
An operation plan allows you to execute it on series or in parallel; in addition, you can set an operation to ignore or retry steps upon error.
Figure 5-1 shows the roadmap for Oracle Site Guard operations. Steps marked optional are required if the site topology and operation plans require the configuration. However, since most enterprise deployments are large, they typically require all the configuration steps in the workflow.
Figure 5-1 Workflow for Oracle Site Guard Operations

Note:
-
Before you create operation plans, ensure that you complete the tasks listed in Configuring Oracle Site Guard.
-
You must login using the
EM_SG_ADMINISTRATOR
role privilege to perform configuration tasks. Ensure that you have created the required user credentials as described in Creating Oracle Site Guard Administrator Users.
Managing Operation Plans
An operation plan describes the flow of execution that Oracle Site Guard performs in a disaster recovery operation, and it consists of (ordered) actions that can be executed in series or in parallel.
Before you execute any Oracle Site Guard disaster recovery operation, you must create a plan for that operation.
An operation plan contains steps such as the following:
-
Stopping Oracle HTTP Servers.
-
Stopping the node managers, managed servers, and administration server in an Oracle WebLogic domain.
-
Performing a database role reversal with Oracle Data Guard.
-
Executing custom user scripts at certain points in the operation plan sequence.
Oracle Site Guard creates a default version of the operation plan based on the site topology and the Oracle Site Guard configuration. You can use this default operation plan or customize it depending on your configuration.
Note:
All existing Site Guard operation plans must be deleted and recreated after a major upgrade of the product.Creating Operation Plans
You can create an operation plan with Enterprise Manager Cloud Control Console or with EMCLI commands.
To create an operation plan, use one of the following methods:
Creating an Operation Plan with Enterprise Manager Cloud Control Console
Learn how to create a new operation plan with Enterprise Manager Cloud Control Console.
To create an operation plan with the Enterprise Manager Cloud Control Console:
Creating an Operation Plan with EMCLI Commands
Learn how to create an operation plan with EMCLI commands.
Note:
For information about logging in to the Enterprise Manager Command Line Interface, see Oracle Enterprise Manager Command Line Interface Guide.
To create a new operation plan, use the create_operation_plan
EMCLI command:
emcli create_operation_plan
[-primary_system_name="name_of_primary_system"]
[-standby_system_name="name_of_standby_system"]
[-system_name="name_of_the_system"]
[-operation="name_of_the_operation"]
[-name="name_of_the_operation_plan"]
[-role="role_associated_with_the_system
"]
[-like="name_of_the_operation_plan_from_which_the_steps_are_to_be_copied"
Note:
[ ]
indicates that the parameter is optional.
Parameter | Description |
---|---|
|
The name of your system associated with the primary site. This option is used for switchover or failover operations. |
|
The name of your system associated with the standby site. This option is used for switchover or failover operations. |
|
The name of the system. This option is used for start or stop operations. |
|
The function of the operation. Example: |
|
The name of the operation plan. |
|
The role associated with a system, when you run an operation ( |
- |
Name of the operation plan from which the steps are to be copied. If this option is specified, system name, operation, and role are ignored. |
Creating New Operation Plans with Existing Plans
Create and configure a new operation plan based on an existing operation plan with Enterprise Manager Cloud Control Console.
You can create and configure a new operation plan of any kind by cloning (copying) an existing plan.
To clone a plan with the Enterprise Manager Cloud Control Console:
Editing and Updating Operation Plans
You can edit your operation plan to change the step execution order, to stop/continue step execution when it encounters an error, and to specify which steps are to run in series or parallel.
When editing an operation plan, you can:
-
Change the order of the steps in an operation plan.
-
Enable or disable individual steps in the operation plan.
-
Choose to stop or continue a step in an operation plan if Oracle Site Guard encounters an error while running the operation plan.
-
Customize each step to execute steps in a serial order or parallel on different hosts.
-
Customize execution groups to sequence operation plan steps in a specific order.
-
Change the timeout for an individual operation step.
You can save the updated operation plan at any point.
Editing and Updating Operation Plans with Enterprise Manager Cloud Control Console
Learn how to edit an operation plan with Enterprise Manager Cloud Control Console.
To edit and update an operation plan with Enterprise Manager Cloud Control Console:
-
Login to Enterprise Manager with
EM_SG_ADMINISTRATOR
role privileges. -
From the Targets menu, click Systems.
The Systems page is displayed.
-
On the Systems page, click the name of the system (Generic System) for which this plan is being created.
The Generic System page for that site is displayed.
-
On the system's home page, from the Generic System > Site Guard > Operations.
The Site Guard Operations page is displayed.
A list of configured operation plans is displayed in the Operation Plans tab.
-
Select an existing operation plan by clicking on the plan listed in the Plan Name column.
The steps associated with the selected operation plan are listed in the Operation Details table located below the Operation Plan table. Each row in the table represents a step that is executed as part of the operation plan.
-
Select View > Columns > Show All to display all columns in the Operation Plan details table, including the additional columns for Script Id, Execution Group and Timeout (sec).
-
Click Edit to enable the options for updating and customizing the steps in the operation plan.
-
Select Move Up (green arrow), Move Down (red arrow), or Delete Step to sequence the steps in the operation plan.
In addition, select the attribute from the Error Mode, Execution Mode, or Run Mode columns.
An operation plan step cannot be moved out of the group it belongs to.
-
To use execution groups to sequence operation steps in a operation group:
-
Set the Execution Mode for the operation group to Parallel.
-
Select the Execution Group for each step in the operation group
All the steps in an execution group are executed in parallel. All the steps that share an execution group will not begin execution until all the steps in the previous execution group have finished execution.
If the execution mode is Serial, execution groups do not apply. The steps are always executed sequentially in the order they are listed.
-
-
To change the timeout for a step in the plan, type in a new timeout value for that step.
-
Click Save to update the plan.
Editing and Updating Operation Plans with EMCLI Commands
Learn how to manage an operation plan with EMCLI commands.
Note:
For information about logging in to the Enterprise Manager Command Line Interface, see Oracle Enterprise Manager Command Line Interface Guide.
To edit or update an operation plan, use the get_operation_plans
, get_operation_plan_details
, and update_operation_plan
EMCLI commands.
Adding and Deleting Operation Plan Tags with EMCLI Commands
Learn how to manage tags for an operation plan with EMCLI commands.
Note:
For information about logging in to the Enterprise Manager Command-Line Interface, see Oracle Enterprise Manager Command Line Interface Guide.
To manage tags (alphanumeric identifier strings) for an operation plan, use the add_operation_plan_tags
and delete_operation_plan_tags
EMCLI commands.
Deleting an Operation Plan
Learn how to delete an operation plan with Enterprise Manager Cloud Control Console or EMCLI commands.
To delete an operation plan, use either of the following tasks:
Note:
All existing Site Guard operation plans must be deleted and recreated after a major upgrade of the product.Deleting an Operation Plan with Enterprise Manager Cloud Control Console
Learn how to delete an operation plan with Enterprise Manager Cloud Control Console.
To delete an operation plan with Enterprise Manager Cloud Control Console:
Deleting an Operation Plan with EMCLI Commands
Learn how to delete an operation plan with EMCLI commands.
Note:
For information about logging in to the Enterprise Manager Command Line Interface, see Oracle Enterprise Manager Command Line Interface Guide.
To delete an operation plan, use the delete_operation_plan
EMCLI command.
emcli delete_operation_plan
–name="name_of_the_operation_plan"
Parameter | Description |
---|---|
|
The name of the operation plan to delete. |
Running Prechecks
Before executing an operation plan Oracle Site Guard runs checks, which you can also run separately to ensure that your operation plan is ready for execution.
Before performing an operation plan Oracle Site Guard runs, by default, the Precheck utility. You can also run this utility separately at any time to ensure that your plan is ready for execution.
The Precheck utility performs the following checks:
-
Checks the agent status on all hosts involved in the operation.
-
Checks if any new targets are added to the generic system after the operation plan is created.
-
Checks if all targets involved in the operation plan exist in the Enterprise Manager repository.
-
Detects if any targets are moved out or deleted from the generic system after the operation plan is created.
-
Performs Storage Role Reversal.
-
Runs Oracle Data Guard Broker Prechecks to ascertain whether the Database is ready for role reversal (for switchover/failover operation).
-
Performs Database Role Checks.
-
Performs Database Lag (Apply and Transport) Checks.
-
Runs checks on ZFS storage appliances to assert the role-change readiness.
Running Precheck Utility with Enterprise Manager Cloud Control Console
Learn how to check an operation plan with Enterprise Manager Cloud Control Console.
To run the Precheck utility with Enterprise Manager Cloud Control:
To track the progress and results of the Precheck, click the click here link in the Confirmation pane at the top of the page, or navigate to Enterprise > Provisioning and Patching > Procedure Activity.
For details about monitoring a procedure activity, see Monitoring Oracle Site Guard Operations.
Running Precheck Utility with EMCLI Commands
Learn how to check an operation plan with EMCLI commands.
Note:
For information about logging in to the Enterprise Manager Command Line Interface, see Oracle Enterprise Manager Command Line Interface Guide.
To run the Precheck utility, use the run_prechecks
EMCLI command.
emcli run_prechecks
-operation_plan="operation_plan_name"
[-database_lag_checks="true"|"false"]
Note:
[ ]
indicates that the parameter is optional.
Parameter | Description |
---|---|
|
Enter the name of your operation plan. |
|
Run database lag checks as part of Prechecks for all data guard configured databases. This parameter is optional. The default value is |
Scheduling and Stopping Health Checks
Health checks are scheduled, periodic checks that can help you assess and monitor your disaster-recovery readiness on an ongoing basis.
Scheduling a Health Check with Enterprise Manager Cloud Control Console
Learn how to schedule a health check with Enterprise Manager Cloud Control Console.
To schedule Health Checks with Enterprise Manager Cloud Control Console:
To inspect the results for each Health Check, navigate to Enterprise > Provisioning and Patching > Procedure Activity.
For more information about monitoring procedure activity see Monitoring Oracle Site Guard Operations.
Scheduling a Health Check with EMCLI Commands
Learn how to schedule a health check with EMCLI commands.
Note:
For information about logging in to the Enterprise Manager Command Line Interface, see Oracle Enterprise Manager Command Line Interface Guide.
To schedule a Health Check, use the schedule_siteguard_health_cheks
EMCLI command:
emcli schedule_siteguard_health_checks -operation_plan="name of the operation plan" -schedule= { start_time:yyyy/MM/dd HH:mm; [tz:{java timezone ID};] [frequency:interval/weekly/monthly/yearly;] [repeat:tx;] [-email="email address to be notified] [-notify_on_failure "flag specifying email notifications will be sent on failed health check only"] [end_time:yyyy/MM/dd HH:mm;] [grace_period:xxx;] }
Note:
[ ]
indicates that the parameter is optional.
Parameter | Description |
---|---|
|
Enter the name of your operation plan. |
|
The schedule for the health check. Enter the values for the following parameters: - - - If the frequency is set to If the frequency is set to If the frequency is set to - - If frequency is set to If the frequency is set to - - - For example: Examples: start_time:2014/06/10 15:45 start_time:2014/10/29 2:00;frequency:interval;repeat:1d start_time:2014/08/10 01:00;frequency:interval;repeat:1w start_time:2014/08/10 01:00;frequency:weekly;days:6,7;grace_period:60;tz:America/New_York |
|
The email address to use for notifications. This e-mail address must be a configured e-mail address for the current user. (Optional) |
|
If set, health check report will be e-mailed on failed execution only. (Optional) |
Note:
When the Oracle Enterprise Manager job system cannot start the execution of a job within the scheduled time plus the grace period, it sets the job status to Skipped. By default, health check jobs are scheduled with unbound grace periods.
Stopping a Health Check with Enterprise Manager Cloud Control Console
Learn how to stop a health check with Enterprise Manager Cloud Control.
To stop a scheduled health check with the Enterprise Manager Cloud Control:
Stopping a Health Check with EMCLI Commands
Learn how to stop a health check with EMCLI commands.
Note:
For information about logging in to the Enterprise Manager Command Line Interface, see Oracle Enterprise Manager Command Line Interface Guide.
To stop a scheduled health check, use the stop_siteguard_health_checks
EMCLI command:
emcli stop_siteguard_health_checks -operation_plan="name of the operation plan"
Parameter | Description |
---|---|
|
The name of your operation plan. |
Executing Oracle Site Guard Operation Plans
You can execute Oracle Site Guard operation plans with Enterprise Manager Cloud Control Console or with EMCLI commands.
To execute operation plan, use either of the following tasks:
Executing Oracle Site Guard Operation Plan with Enterprise Manager Cloud Control Console
Learn how to execute an operation plan with Enterprise Manager Cloud Control Console.
To execute an operation plan with Enterprise Manager Cloud Control Console:
To track the progress and results of the operation, click the click here link in the Confirmation pane at the top of the page, or navigate to Enterprise > Provisioning and Patching > Procedure Activity.
For more details about monitoring a procedure activity see Monitoring Oracle Site Guard Operations.
Executing Oracle Site Guard Operation Plan with EMCLI Command
Learn how to execute an operation plan with EMCLI commands.
Note:
For information about logging in to the Enterprise Manager Command Line Interface, see Oracle Enterprise Manager Command Line Interface Guide.
To execute an operation plan, use the submit_operation_plan
EMCLI
command:
emcli submit_operation_plan -name="name_of_operation_plan" [-run_prechecks="true | false"] [-stop_primary="flag_specifying_whether_primary_site_to_be_stopped_during_failover"] [-database_lag_checks="true"|"false"] [-ignore_warnings]
Note:
[ ]
indicates that the parameter is optional.
Parameter | Description |
---|---|
|
The name of the operation plan. |
|
The By default, the value of this parameter is If you set the value to |
|
Whether to stop targets on primary site during a Failover operation. Set value |
|
Run database lag checks as part of Prechecks for all Data Guard configured databases. This parameter is optional. The default value is |
|
When specified non-fatal warnings will be ignored during failovers. |
Monitoring Oracle Site Guard Operations
You can monitor Oracle Site Guard operation plan executions with Enterprise Manager Cloud Control Console or with EMCLI commands.
To monitor an operation activity, use either of the following methods:
Monitoring an Operation Plan with Enterprise Manager Cloud Control Console
You can view, suspend, resume, or stop an operation activity with Enterprise Manager Cloud Control Console.
To monitor and manage operation activity, use the following tasks:
Viewing an Operation Activity
Learn how to view operation activity with Enterprise Manager Cloud Control Console.
To monitor an operation activity submitted for execution with Enterprise Manager Cloud Control Console:
Suspending, Resuming, or Stopping an Operation
Learn how to manage an operation execution with Enterprise Manager Cloud Control Console.
Operations in progress can be suspended and resumed later. You can also stop the operations that you do not want to resume.
To manage operation plans with Enterprise Manager Cloud Control Console:
Monitoring an Operation Plan with EMCLI Commands
Learn how to monitor operation plan executions with EMCLI commands.
Note:
For information about logging in to the Enterprise Manager Command Line Interface, see Oracle Enterprise Manager Command Line Interface Guide.
To monitor the status of an operation plan, use the get_instances
and get_instance_status
EMCLI commands.
Managing Execution Errors
Oracle Site Guard uses Enterprise Manager Cloud Control deployments to orchestrate disaster recovery operations on remote hosts. This framework provides error management support through execution error modes.
Errors encountered during an operation plan execution can be managed in multiple ways. Oracle Site Guard provides an option to define the error mode for individual steps, and also lets you enable or disable steps. For example, if an operation step has an associated error mode of 'Stop on Error', Oracle Site Guard stops the operation when it encounters and error while executing that step.
To retry the step that raised the error and to continue the operation:
Manually Reversing Site Roles
You can manually reconfigure site roles and explicitly designate a site as the primary site while testing disaster recovery work flows or in isolated parts of some work flows.
When you designate a site as a primary site, or manually reconfigure site roles, the other site is automatically designated as the Standby site.
Manually Reversing Site Roles with Enterprise Manager Cloud Control Console
Learn how to manually reconfigure site roles with Enterprise Manager Cloud Control Console.
To manually reconfigure site roles with Enterprise Manager Cloud Control Console:
Manually Reversing Site Roles with EMCLI Commands
Learn how to manually reverse the roles of the primary and secondary sites.
Note:
For information about logging in to the Enterprise Manager Command Line Interface, see Oracle Enterprise Manager Command Line Interface Guide.
To manually reverse the roles of the primary and standby sites, run the update_siteguard_configuration
EMCLI command.
emcli update_siteguard_configuration -primary_system_name="primary_system_name" -standby_system_name="standby_system_name" [-reverse_role="flag_specifying_whether_system_roles_to_be_reversed"] [-role="new role for the standby site"]
Note:
[ ]
indicates that the parameter is optional.
Parameter | Description |
---|---|
|
The name of the system that is the current primary site and needs to be designated as the new standby site. |
|
The name of the system that is the current standby site and needs to be designated as the new primary site. |
|
Reverse roles between primary and standby systems. Optional. If specified, only one standby system can be specified with the |
|
The new role for the site. Optional. One of the following:Primary, Standby, or ValidateStandby. Optional flag.
|