Home >Database >Oracle >How to turn off auditing in oracle

How to turn off auditing in oracle

WBOY
WBOYOriginal
2022-03-03 16:19:126460browse

In Oracle, you can use the alter statement and the "audit_trail" parameter to turn off the audit function. The "audit_trail" parameter can control the opening and disabling of auditing. The syntax is "alter system set audit_trail=FALSE scope=spfile".

How to turn off auditing in oracle

The operating environment of this tutorial: Windows 10 system, Oracle 11g version, Dell G3 computer.

How to turn off auditing in oracle

1. Turn off the audit function

1. Check whether the audit function is turned on?

su – oracle
sqlplus “/as sysdba”
SQL> show parameter audit_trail
NAME TYPE VALUE
audit_trail string DB

Explanation: The VALUE value is DB, and the surface audit function is turned on

2. Turn off the audit function of Oracle

SQL> alter system set audit_trail=FALSE scope=spfile;
System altered.

3. Restart the database

SQL> shutdown immediate;
SQL> startup;

4. Verify whether the audit has been closed

SQL> show parameter audit_trail
NAME TYPE VALUE
audit_trail string FALSE

Description: The VALUE value is FALSE, and the surface audit function is closed

2. Delete the audit log

When it has been When a log is formed, the records in it can be deleted. Currently, they are deleted directly without affecting the database.

Query the current log information: select * FROM SYS.AUD$;

Delete existing audit information: DELETE FROM SYS.AUD$;

Or quickly delete the table Information: truncate table SYS.AUD$;

Recommended tutorial: "Oracle Video Tutorial"

The above is the detailed content of How to turn off auditing in oracle. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn