Skip to Main Content

Database Software

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Generating Audit Logs in XML format.

Akanshi KumariMar 11 2025

Hi Team,
I am trying to generate Audit logs for Oracle 23ai in XML format.
I have followed these steps:
1. To check if it is enabled, run: SELECT VALUE FROM V$OPTION WHERE PARAMETER = 'Unified Auditing';

2. Enable XML Format for Audit Logging:

ALTER SYSTEM SET AUDIT_TRAIL=XML SCOPE=SPFILE;

SHUTDOWN IMMEDIATE;

STARTUP;

2. Check Available Audit Policies: SELECT POLICY_NAME FROM AUDIT_UNIFIED_POLICIES;

3. Create a New Table for Testing :

CREATE TABLE test_table (

id NUMBER PRIMARY KEY,

name VARCHAR2(100)

);

4. Create a Unified Audit Policy:

CREATE AUDIT POLICY audit_test_policy

ACTIONS SELECT, INSERT, UPDATE, DELETE

ON test_table;

5. Enable the Audit Policy:

AUDIT POLICY audit_test_policy;

AUDIT POLICY audit_test_policy BY FREEUSER;

6: Perform Some Actions to Generate Logs

7. To check path where audit logs will be store: SHOW PARAMETER AUDIT_FILE_DEST;

After following the all steps mentioned above, I am not able to collect audit logs for the operations I performed. Is there any step, I have missed or doing wrong?

Comments
Post Details
Added on Mar 11 2025
1 comment
260 views