LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices



Reply
 
Search this Thread
Old 11-03-2011, 10:59 AM   #1
veeruk101
Member
 
Registered: Mar 2005
Distribution: Ubuntu 12.04 LTS
Posts: 249

Rep: Reputation: 16
Logrotate - what is rotating /var/log/audit/audit.log?


/var/log/audit/audit.log seems to be getting rotated, but I'm not sure what's causing it because there doesn't seem to be configuration for it in any logrotate config files.

I'd like to create my own logrotate rules to rotate it when it hits a certain size (because the files are too large for my liking), but I don't know where to change it... I could ADD a logrotate configuration for audit.log but I don't know how it would interfere with the existing log rotation rule for this log, wherever it is.
 
Old 11-03-2011, 03:18 PM   #2
MensaWater
Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 6,028
Blog Entries: 5

Rep: Reputation: 791Reputation: 791Reputation: 791Reputation: 791Reputation: 791Reputation: 791Reputation: 791
/etc/audit/auditd.conf has the rotation rules for this log. The rotation is size based rather than time based by default.

Typing "man auditd.conf" will give you details on how to configure the rules.
 
Old 11-03-2011, 08:36 PM   #3
veeruk101
Member
 
Registered: Mar 2005
Distribution: Ubuntu 12.04 LTS
Posts: 249

Original Poster
Rep: Reputation: 16
I'd like logrotate to manage the rotation, so I'm setting max_log_file_action to IGNORE instead of ROTATE, and adding a rule in logrotate for audit.log. I hope that does it.
 
Old 11-03-2011, 08:53 PM   #4
unSpawn
Moderator
 
Registered: May 2001
Posts: 27,766
Blog Entries: 54

Rep: Reputation: 2976Reputation: 2976Reputation: 2976Reputation: 2976Reputation: 2976Reputation: 2976Reputation: 2976Reputation: 2976Reputation: 2976Reputation: 2976Reputation: 2976
Quote:
Originally Posted by veeruk101 View Post
I'd like to create my own logrotate rules to rotate it when it hits a certain size (because the files are too large for my liking)
Using logrotate only due to file size may not address the actual cause. Depending on what logging is produced versus what is required I suggest tweaking your current rule set before settling for a panacea.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Audit Log k_balaa Linux - Newbie 4 04-30-2011 12:02 AM
[Linux Audit]: Which groups should be allowed to read audit log files? quanba Linux - Security 1 11-15-2010 11:09 AM
kernel audit - var/log/messages timinator Linux - Security 1 11-13-2007 04:02 PM
/var/log/messages - kernel: audit(1107868785.573:0): avc: denied { getattr } lothario Linux - Security 2 02-10-2005 05:24 AM
Audit Log in AIX? DriveMeCrazy AIX 5 05-16-2004 04:37 PM


All times are GMT -5. The time now is 09:03 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration