I m using LogMiner for scanning my archive logs. I use following sequence:
1. Get a connection for LogMiner session.
2. Add the required log files to the LogMiner session.
3. Start the LogMiner, using DBMS_LOGMNR.START_LOGMNR(...).
4. Read from the view V$LOGMNR_CONTENTS, using a select query.
This is working perfectly fine. The list of available archive file names can be obtained from the view: V$ARCHIVED_LOG. From my (java) program i span a thread which does all these jobs for me. (NOTE: Its not mandatory to have the connection (for LogMiner) to the same instance for which the scanning is performed. ie., If i m scanning the log files of instance 'Sales', i can get the connection for instance 'Purchase' and start the LogMiner).
-------------------------------------
Question-1: At times, i m getting the following error:
"java.sql.SQLException: ORA-01306: dbms_logmnr.start_logmnr() must be invoked before selecting from v$logmnr_contents". I m not sure, why this error is occuring in a very rare frequency.
-------------------------------------
Question-2: When i want to scan the log files of two instances (say 'db1', 'db2'), i span two threads, one for each database. But i m getting the connection with different instance (say, 'common'). Now i m getting the result of one scan, for both the scans, which is not correct. But if i get the connection with 'SYSDBA' previlages, this is working properly. I couldnt get any clues, why this needs SYSDBA previlages.
Can anyone help pls?
thanks,
madhes
1. Get a connection for LogMiner session.
2. Add the required log files to the LogMiner session.
3. Start the LogMiner, using DBMS_LOGMNR.START_LOGMNR(...).
4. Read from the view V$LOGMNR_CONTENTS, using a select query.
This is working perfectly fine. The list of available archive file names can be obtained from the view: V$ARCHIVED_LOG. From my (java) program i span a thread which does all these jobs for me. (NOTE: Its not mandatory to have the connection (for LogMiner) to the same instance for which the scanning is performed. ie., If i m scanning the log files of instance 'Sales', i can get the connection for instance 'Purchase' and start the LogMiner).
-------------------------------------
Question-1: At times, i m getting the following error:
"java.sql.SQLException: ORA-01306: dbms_logmnr.start_logmnr() must be invoked before selecting from v$logmnr_contents". I m not sure, why this error is occuring in a very rare frequency.
-------------------------------------
Question-2: When i want to scan the log files of two instances (say 'db1', 'db2'), i span two threads, one for each database. But i m getting the connection with different instance (say, 'common'). Now i m getting the result of one scan, for both the scans, which is not correct. But if i get the connection with 'SYSDBA' previlages, this is working properly. I couldnt get any clues, why this needs SYSDBA previlages.
Can anyone help pls?
thanks,
madhes