If the Connect CDC Kernel is not configured with the delete archive logs option, Connect CDC creates a corresponding empty file in the primary archive directory for each archive log that has been processed and is no longer needed for replication. Connect CDC creates these empty files in the Archive subdirectory of the location where Connect CDC has been installed.
Connect CDC assigns the empty file the same name as Oracle assigns to the archive log with .repdone appended to the name. Thus, any file that ends with .repdone represents a processed archive log that is safe to be backed up and deleted. For example, when Oracle creates archive logs with the following names:
C:\Oracle9.2\oradata\ORCL\archive\OMNI1_3649.ARC
C:\Oracle9.2\oradata\ORCL\archive\OMNI1_3650.ARC
C:\Oracle9.2\oradata\ORCL\archive\OMNI1_3651.ARC
After the above files have been processed and are no longer required for replication, Connect CDC creates the following empty files:
...\kernel\Archive\OMNI1_3649.ARC.repdone
...\kernel\Archive\OMNI1_3650.ARC.repdone
...\kernel\Archive\OMNI1_3651.ARC.repdone
These empty .repdone files can be used to coordinate the backup and deletion of archive logs when archive log management is handled manually using a script. The following are possible steps to handle archive log deletion with a script.
-
Read in all *.repdone files from the primary archive directory
-
Remove the .repdone suffix to get the actual archive name.
-
Backup and delete the archive log.
-
Delete the empty .repdone file.
-
Get the next .repdone file to process and return to step 2.