Increase The audit.log rotation

Discuss your pilot or production implementation with other Zimbra admins or our engineers.
Post Reply
m3ds
Posts: 2
Joined: Fri Sep 15, 2017 10:06 am

Increase The audit.log rotation

Post by m3ds »

Hello mates,

I want to keep the audit.log files more than the default value of Zimbra which think it's around 10 or 8 days.
I made some searches and figured out it's all about to change the log4j.properties file but i didn't find any configuration parameters.
Does anyone know what should i do to solve this Log rotation subject.


Regards.
ssonawane
Posts: 4
Joined: Fri Sep 15, 2017 11:26 am

Re: Increase The audit.log rotation

Post by ssonawane »

If you login with zimbra user and see "crontab -l" list , you will find the command as below to maintain "/opt/zimbra/log" files. You will need to adjust days as it is set as 8 by default.

find /opt/zimbra/log/ -type f -name \*.log\* -mtime +8 -exec rm {} \;

Note that it will be applied for all log files in that directory.
m3ds
Posts: 2
Joined: Fri Sep 15, 2017 10:06 am

Re: Increase The audit.log rotation

Post by m3ds »

Thank you for your help but there's a problem the first line of this file says:

# ZIMBRASTART -- DO NOT EDIT ANYTHING BETWEEN THIS LINE AND ZIMBRAEND
you know i think it's gonna be overwrite every time I restart the server. But let me change and test the scenario.

Regards.
ssonawane
Posts: 4
Joined: Fri Sep 15, 2017 11:26 am

Re: Increase The audit.log rotation

Post by ssonawane »

The first line is a comment. You'll need to search the line as I mentioned earlier and update it.
Post Reply