It is common to receive permission errors in the capture/extract process of Oracle GoldenGate (OGG) running on Microsoft Windows servers with Oracle Database. The capture process reads the Oracle redo and archive logs to find the committed transactions. When an Oracle Database is installed on Windows servers, the redo logs and the archive log directory are created in protected mode, and a standard user will not have permission to read them. To circumvent this error, make sure that the OGG user has read access to the Oracle redo logs and the archive log directory.
When does this occur?
Normally this type of permission errors are seen after
- installation of Oracle GoldenGate and starting Capture process for the first time
- adding additional Redo logs in Oracle
- changing or moving the Archive Log destination in Oracle
Types of Errors
When the OGG user does not have permission to read the Oracle redo log, the capture process will crash. Error messages are generated in the capture report file. Samples of the capture report file taken from two different OGG installations are listed below. The error message generated from the Oracle database can be different depending on the version of the Oracle database, but the basic message Permission denied or Access is denied will be part of the error message.
Capture report file from first installation:
2013-07-31 20:44:15 ERROR OGG-01028 Oracle GoldenGate Capture for Oracle, EXTLOCAL.prm: error 13 (Permission denied) opening redo log D:\ORACLE_INSTALL_SW\ORACLE_DB11G\ORADATA\ORCL\REDO02.LOG for sequence 644.
2013-07-31 20:44:15 ERROR OGG-01668 Oracle GoldenGate Capture for Oracle, EXTLOCAL.prm: PROCESS ABENDING.
Capture report file from second installation:
2013-08-22 09:08:53 ERROR OGG-00446 Oracle GoldenGate Capture for Oracle, ETEST.prm: Error 5 (Access is denied.) opening log file C:\APP\ORACLE\ORADATA\ORA11\REDO01.LOG for sequence 10. Not able to establish initial position for begin time 2013-08-22 09:05:39.
2013-08-22 09:08:53 ERROR OGG-01668 Oracle GoldenGate Capture for Oracle, ETEST.prm: PROCESS ABENDING.
When the OGG user does not have permission to read the Oracle archive log directory, the capture process will crash, and an error message similar to one shown below will be written to the capture report file.
2013-08-29 13:38:36 ERROR OGG-00446 Could not find archived log for sequence 20 thread 1 under default destinations SQL <SELECT name FROM v$archived_log WHERE sequence# = ora_seq_no AND thread# = ora_thread AND resetlogs_id = ora_resetlog_id AND archived = 'YES' AND deleted = 'NO' AND name not like '+%' AND standby_dest = 'NO' >, error retrieving redo file name for sequence 20, archived = 1, use_alternate = 0Not able to establish initial position for begin time 2013-08-29 13:13:58.
2013-08-29 13:38:36 ERROR OGG-01668 PROCESS ABENDING.
When the OGG user does not have permission to read an Oracle Archive log file, an error message similar to one shown below will be written to the report file:
2013-08-29 14:25:41 ERROR OGG-01028 error 13 (Permission denied) opening redo log C:\APP\ORACLE\FAST_RECOVERY_AREA\ORA11\ARCHIVELOG\2013_08_29\O1_MF_1_35_91Z3VYFJ_.ARC for sequence 35.
After giving the required read access to the OGG user, restart the capture process and it will continue to run.
How to Change File Permissions in a Windows Server
For the benefit of users who are not familiar with changing file permissions in a Windows server, step-by-step instructions are given below:
1. Open Windows Explorer and locate the file for which you are checking permissions (REDO01 in example shown below). The capture report file contains the directory and file name for which permission is required.
2. Right click on the file name and select properties
3. Click on the Security Tab on top
You will not see the OGG user (gguser in this example) listed in Group or user names if the OGG user doesn’t have permissions to read this file. If you see the OGG user listed there, make sure the user has read access to the file.
4. To add the OGG user (gguser) click on “Edit”.
5. Click on “Add” to add the OGG user (gguser).
6. Add the OGG user (gguser) and click on “Check Names” to make sure the user name exists. Click on OK to add the OGG user (gguser).
You should see the OGG user (gguser) in the list with Read and Read and Execute permissions.
7. Click on “Apply” and then “OK” and “OK” again on the next screen.
Repeat the steps for other Redo log files and Archive log directory.