Linux log rotation not working

I recently set up a log rotation using a combination of the crontab and logrotate commands. Every week the log file /var/log/notes/domino.log gets moved to /var/log/notes/domino.log-yyyymmdd and a new domino.log gets created.

The problem is that Domino seems to hang onto the inode and not the file name. So after the domino.log gets renamed, Domino continues to send logging information to the new file name. The new domino.log doesn’t get touched because (I’m assuming) the inode is different.

Has anyone come up with a solution to this that DOESN’T involve restarting the Domino server once a week to coincide with the log rotation?

Subject: Solution: Linux log rotation not working

There is an option in logrotate, copytruncate, that allows for programs which don’t respond to the ‘killall -HUP’ command. This causes logrotate to create a new file, copy the contents of the domino.log into it, and then truncate the domino.log file. No restart of Domino is required.

Hope this is helpful to someone.

Subject: RE: Solution: Linux log rotation not working

Hi Scott,

Will you be able to post you start script for Domino here. How do you start the server and pipe the log to the logger??

Thanks.

Kjeld