LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Increase Audit Log size in RHEL 3.0? (https://www.linuxquestions.org/questions/linux-newbie-8/increase-audit-log-size-in-rhel-3-0-a-322500/)

spelltoronto 05-11-2005 04:30 PM

Increase Audit Log size in RHEL 3.0?
 
Hi,

Is there a way to increase the system audit logs size so that it can hold more auditing information, for a longer period of time. It seems the logs in RHEL 3.0 only go back a few days...

Thanks

bnj 05-12-2005 01:54 AM

Dirty workaround: log your logs. Using a cronjob, you can make your own copy of the logs.

I'm sorry but I do not have a better idea at the moment.

spelltoronto 05-13-2005 01:17 AM

Can someone paste in a cronjob script that would copy the sytem logs and save them to a seperate directory?

Sorry, I'm a newbie... :)

Thanks

bnj 05-17-2005 02:21 AM

Here is the code of the script. Store it as myscript.sh

Code:

#!/bin/bash
MOMENT=$(date +%Y.%m.%d_%H%M%S)
cp /path/to/your/log/files/here.log /path/to/your/backup/here.$MOMENT.bak
gzip /path/to/your/backup/here.$MOMENT.bak

And edit your crontabs using the command
Code:

$ crontab -e
(you will have to know the vi editor)
Then paste this job:
Code:

#0 1 * * * /path/to/your/script/myscript.sh

spelltoronto 05-17-2005 06:29 PM

Thanks! I'll give that a try....


All times are GMT -5. The time now is 05:01 PM.