As an Oracle Database Administrator, one of the common challenges faced by DBAs is ensuring that the Disaster Recovery (DR) system is in sync with the Primary server. The DR system is crucial because it allows businesses to continue their operations even in the event of a disaster affecting the primary server. However, sometimes the DR system can be out of sync, and the GAPS may be increasing, which can cause data loss and other problems.
In this blog, we will explore how to resolve this issue when there is not enough space on the mount point logically, but physically, space is present.
The first step to resolving this issue is to investigate the root cause. In this case, when we dug deeper into the alert log, we found the error that there is not enough space on the mount point logically, but physically space was present. This error can occur when there is a mismatch between the logical and physical space available.
To resolve this issue, we need to ensure that the controlfile knows which archives have been deleted but are still present logically.
To do this, we can run the crosscheck archivelog all command in the RMAN prompt. This command checks for the existence of the archived redo logs that are specified in the RMAN repository but not on the disk.
Here’s the SQL command to check the current status of the archive logs:
SELECT NAME, APPLIED, CREATION_TIME FROM V$ARCHIVED_LOG ORDER BY FIRST_TIME DESC;
This command will display the list of all archived redo logs, along with their status and creation time.
To run the crosscheck archivelog all command in the RMAN prompt, follow the below steps:
Step 1: Connect to RMAN:
$ rman target /
Step 2: Run the crosscheck archivelog all command:
RMAN> crosscheck archivelog all;
Step 3: Once the crosscheck is complete, run the delete expired command to remove any expired archive logs:
RMAN> delete expired archivelog all;
By running the crosscheck archivelog all command, we can ensure that the controlfile is aware of the archived redo logs that have been deleted but are still present logically. This can help resolve the issue of the DR system being out of sync with the primary server and the GAPS increasing.
In conclusion, maintaining the DR system is critical to ensure business continuity, and DBAs must ensure that it is in sync with the primary server.
When facing issues with the DR system being out of sync, it’s essential to investigate the root cause and take necessary steps to resolve it.
Running the crosscheck archivelog all command in the RMAN prompt can help ensure that the controlfile is aware of any archived redo logs that have been deleted but are still present logically.