Applying a Patch to a Test Deployment

You can use the clonedb option of the dbpatchm subcommand to apply a patch to a test deployment of Oracle Database Cloud Service before you apply it to a live, production database deployment.

Note:

Currently, applying a patch to a test deployment is not supported for database deployments that use Oracle Real Application Clusters (RAC).

To apply a patch to a test deployment:

  1. Using the Create Instance wizard, create a test deployment on Database Cloud Service, providing the same information as you did when creating the live deployment.
  2. Connect as the opc user to the test deployment and then perform these steps:
    1. Start a root-user command shell:
      $ sudo -s
      #
    2. Run the following commands:
      # cd /home/oracle
      # ./deinstall.pl -dbname=dbname
      ...
      # /var/opt/oracle/ocde/ocde -dump -alist=prep sda
      ...
      #
    3. Exit the root-user command shell and disconnect from the test deployment.
  3. Copy the SSH private key file for the SSH key used when creating the test deployment to the live deployment.
  4. Connect as the opc user to the live deployment and then start a root-user command shell:
    $ sudo -s
    #
  5. Edit the /var/opt/oracle/patch/dbpatchm.cfg patching configuration file, setting the normal keys to perform a patching operation. In addition, set the following keys:
    • cloning: set this key to yes

    • remotenode: set this key to the IP address of the test deployment

    • sshkey_fl: set this key to value of the SSH private key file you copied to the live deployment

    • upg: set this key to upg

  6. Apply the patch to the test deployment using the dbpatchm subcommand of dbaascli:
    # dbaascli dbpatchm --run -clonedb
    

    The dbpatchm subcommand displays progress as it copies information from the live deployment to the test deployment and then applies the patch to the test deployment.

  7. Exit the root-user command shell and disconnect from the test deployment.
After applying the patch to the test deployment, confirm appropriate application of the patch on the test deployment. When satisfied, you can delete the test deployment and apply the patch to the live deployment.