Is it possible to audit SQL statements (including that of triggers) in a way that they are written to a text file?
I've enabled Audit Trail in DB mode but don't have the slightest idea on where to get the executed statements.
TIA
Printable View
Is it possible to audit SQL statements (including that of triggers) in a way that they are written to a text file?
I've enabled Audit Trail in DB mode but don't have the slightest idea on where to get the executed statements.
TIA
Arda,
AUDIT_TRAIL=DB enables systemwide auditing where audited records are written to the database audit trail, the SYS.AUD$ table
AUDIT_TRAIL=OS enables systemwide auditing where audited records are written to the operating system's audit trail
AUDIT_TRAIL=NONE disables auditing. This is the default value.
If you have set AUDIT_TRAIL = OS, modify the "init.ora" file to specify the destination for the audited records using the AUDIT_FILE_DEST parameter.
To get the auditing information from SYS.AUD$ spool the info you need to text file.
Hope that helps,
--clio_usa
Senior Oracle DBA
Visit the latest Oracle DBA forums:
http://www.dbaclick.com/cgi-bin/ib3/ikonboard.cgi
---------------------------------------------------------
Thanks Pal.
Clio,
AUDIT_FILE_DEST is a 9i parameter, isn't it?
8i reports it as an "unknown parameter". Is there a workaround??
QUOTE
--------
spool the info you need
--------
What would that info be (i.e: which records should I select from SYS.AUD$) in order to retrieve the SQL statements ?
TIA
No, it's available in 8i.Quote:
Originally posted by Arda
Clio,
AUDIT_FILE_DEST is a 9i parameter, isn't it?
You should specify the OS you are using. I assume you are using NT/2000, as AUDIT_FILE_DEST is realy not supported on that platform. In NT/2000 OS audit trail is allways written to the system's EventLog, you can't redirect it to another file.Quote:
8i reports it as an "unknown parameter". Is there a workaround??
I see. In fact it IS Nt.
Thanks.