Oracle Autonomous Database offers a great feature for creating refreshable clones. These clones are typically refreshed hourly, which works well for many use cases. However, if your business requires a shorter refresh interval to meet more demanding availability or recovery goals, you can configure your clone to update much more frequently.
Here’s how you can set up a refreshable clone to update every 10 minutes, for example, giving you a near real-time replica of your data.
Important Considerations:
-
Your source database stays online. Your original database remains fully operational and accessible throughout the entire process, so there’s no interruption to your live environment.
-
The clone is for reading only. The target database is accessible in read-only mode, so you can’t make any changes to it. During a refresh, the clone automatically closes and then reopens once the update is complete, ensuring data consistency.
Steps to Create and Refresh an Autonomous Database Clone
- Create an Autonomous Transaction Processing (ATP) instance in OCI
- Provision a Compute VM and install Python + OCI CLI:
Reference: Installing OCI CLI
- Configure authentication:
- Upload the public key to the tenancy: How to upload the public key
- Update the OCI CLI config file with the private key path (~/.oci/config):
- Create the refreshable clone manually:
- Manually refresh the clone using a timestamp 10 minutes in the past:
- Automate the refresh with a shell script to be executed every 10 minutes via crontab:
- Gave execution permissions:
- Configure the cron job:
- Validate execution through logs and the OCI console:
Conclusion
By combining manual refreshes with cron automation, it is possible to maintain a refresh interval as short as 10 minutes for Autonomous Database clones. This approach provides a practical workaround when business requirements demand faster refresh cycles than the default 1-hour minimum supported by Oracle Autonomous Database.
