Prepare the Compute Instances

Oracle Cloud Infrastructure Full Stack Disaster Recovery Service uses Oracle Cloud Agent to run scripts in the compute instances.

Prepare Oracle Cloud Agent in the Compute Instances

Complete the following requirements to allow Oracle Cloud Agent to run scripts in a compute instance:

  1. Ensure that your Oracle Identity Management policies allow the Oracle Cloud Infrastructure Full Stack Disaster Recovery Service to run commands.
    For example,
    • Allow group Administrators to manage instance-agent-command-family in compartment my_compartment.
    • Allow dynamic-group dynamic_group_that_include_compute_instances to use instance-agent-command-execution-family in compartment my_compartment.

    See Running Commands on an Instance

    See Policies for Oracle Cloud Agent

  2. Allow Oracle Cloud Agent to run commands as another user.
    Oracle Cloud Agent runs scripts with the user ocarun. To run scripts with another user (like opc or oracle), requires Administrator privileges.
    1. Provide Administrator privileges to Oracle Cloud Agent in each compute instance where you plan to run custom scripts. See Running Commands with Administrator Privileges
    2. Restart the agent in the compute instances.
      sudo systemctl restart oracle-cloud-agent