• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer navigation

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • Solaris
    • Oracle Linux
    • VCS
  • Interview Questions
  • Database
    • oracle
    • oracle 12c
    • ASM
    • mysql
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

How to Stop Audit Log Entries Written to System Logs in CentOS/RHEL 6

by admin

This post explains how to stop audit log entries written to system logs.

1. Check the file /etc/audisp/plugins.d/syslog.conf. By default, the file “/etc/audisp/plugins.d/syslog.conf will have the below line.

args = LOG_INFO

This will allow syslog to log audit logs into /var/log/messages. In addition audit.d will log all the audit events to /var/log/audit/audit.log too and this is the data normally we use to check audit events.

2. Duplicating the entries in /var/log/messages is not required and it will unnecessarily increase the file size and scatter the other kernel related events. To avoid this, follow the below steps.

Change the file “/etc/audisp/plugins.d/syslog.conf” entry as below

From:

args = LOG_INFO

to:

args = LOG_LOCAL0

3. Then change the file “/etc/rsyslog.conf” entry as below

From:

*.info;mail.none;authpriv.none;cron.none /var/log/messages

to

*.info;mail.none;authpriv.none;cron.none;local0.none /var/log/messages

4. Then restart the auditd and rsyslog services.

# service auditd restart
# service rsyslog restart

This will allow audit.d to log audit logs only to /var/log/audit/audit.log and not to /var/log/messages.

Filed Under: CentOS/RHEL 6, Fedora, Linux

Some more articles you might also be interested in …

  1. MySQL Fails to Start Using systemctl On systemd Linux Distributions
  2. CentOS / RHEL : How to find RPM installation date and time
  3. chntpw : command not found
  4. CentOS / RHEL 5 : How to Configure kdump
  5. Medusa: command not found
  6. dunstify: command not found
  7. esearch: command not found
  8. How to Create Yum Repository For System Packages Installation in CentOS/RHEL
  9. Honeypot Tutorials – Modes and Working of Honeypot
  10. How to mount an iso file in Linux

You May Also Like

Primary Sidebar

Recent Posts

  • powertop Command Examples in Linux
  • powertop: command not found
  • powerstat: command not found
  • powerstat Command Examples in Linux

© 2023 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright