How to create Refreshable Clone on Autonomous Database

 One of the most widely used features in Autonomous Database on Shared Infrastructure (ADB-S) today is the ability to clone your database. This feature enables you to clone your source database easily and create another environment which can be used for development or testing purpose.

There are three types of cloning methods available in ADB such as


  • Full Clone – This creates a new database with the source database’s data & metadata.
  • Refreshable Clone – This creates a read only copy of the source database’s data and metadata.  This can be refreshed with source database’s data periodically as per requirement
  • Metadata Clone –    This creates a new database with only metadata of source database. 

  

Here in this topic I would be talking about Refreshable Clone on Autonomous Database. 



Refreshable Clone Features:-

A refreshable cloned instance is a read-only database, which basically stays connected with the source instance and when required it can pull data from the source instance just by simply clicking on “Refresh Clone” button. The entire cloning operating can take place without knowing much of cloning process nitty gritty.

The refreshable clone has a one week (7 days) refresh age limit. If once do not perform a refresh on the refreshable cloned instance, the cloned instance would no longer be refreshable further. However, the instance can be disconnected from source database and open the database as read write mode.


Step 1: Setting up an Autonomous Database

Login to OCI console.

Lets assume we already have an Autonomous Database created. Here in our demo we are using one Autonomous Transaction Processing database namely ATP-PROD





 







Navigate to Tools, and open SQL Developer Web. We can use SQL Developer which if its available on your local PC. Just make sure the connection towards the ATP-D is working properly. From SQL Developer we would firstly make some changes into the database.




Provide username: Admin and password to login into SQL Developer Web



Now that we have created a table, and inserted data into it. Lets start the cloning process


Step 2. Creating Refreshable Clone from Autonomous Database



Navigate to More Actions -> Click on “Create Clone” option.



Here Select the clone type as “Refreshable Clone” and for display name choose a name as per your convenience. In our case we chose Clone of ATP-PROD.


For Database name we choose a name UAT. Note:The cloned refreshable instance name cant be same as source database’s  name in same OCI region.



Choose the desired Network access type. In our case we choose “Allow secure access from everywhere”. If there is a VCN configured, this can be used as well for private access.

Choose a license type. We choose BYOL in our case.

Note:- For refreshable clone , there is no ADMIN password option available, as the password is inherited from the source database.




Step 3: Insert additional data into the source database

Now once refreshable clone instance is created open the 

SQL developer Web and lets check the data


So we can see the data has been cloned successfully into the refreshable cloned instance. Now let’s insert few more rows into source instance.


Step 4: Refresh the clone instance to view the data


Now here in the above screenshot it clearly shows the time by which cloned instance must be refreshed, else the instance won’t be able to refreshed further




While we hit the “Refresh Clone” button it asks for timestamp from where instance would get refreshed. In our case , we provided the timestamp after the time when we added a row into the table in source instance.


So after querying the table t1 from refreshable instance , we can see the data has been updated into the refreshable cloned instance.

 

So this concludes the testing of refreshable cloned feature in autonomous database.


Good To Know: -

  • Ø  Oracle ADB refreshable clone feature is not available in Always Free Autonomous database.

  • Ø  The Oracle ADB refreshable clone feature is available from Oracle Database 19c onwards in OCI.

  • Ø  To create a refreshable clone, the source database workload type must be either ATP (Autonomous Transaction Processing) or ADW (Autonomous Data Warehousing). Creation of refreshable clone from Autonomous JSON Database is not supported.

  • Ø  It is not possible to create a refreshable clone from another refreshable clone. But creation of  a full or Metadata clone is possible.

  • Ø  If its required to change the ADMIN password in refreshable clone, this must be done on source database followed by a refresh, which would eventually change the ADMIN password in the clone instance

  • Ø  Oracle Machine Learning is disabled in a refreshable clone read-only database. In addition, the OML User Administration URLs are disabled in the Oracle Cloud Infrastructure console and in the Autonomous Database Service Console.

  • Ø  Oracle APEX URL’s do not work in a refreshable clone, as the database runs in read/write mode. The APEX URL’s are disabled in OCI Console and Autonomous database Service Console. The URL are enabled when the database is open in read write mode when the cloned instance is disconnected from source database.

  • Ø  You cannot rename a refreshable cloned instance or database


Business cases where the Refreshable clone can be implemented: -

·            Ã˜  Providing a routinely updated clone to a different business unit within your organization for             reporting and analysis

  • Ø  Creating billing or workload separation for your databases between business units within the organization

  • Ø  Providing up-to-date read-only test database environments to internal teams

No comments:

Post a Comment