0
According to the man page "Normally, logrotate is run as a daily cron job. It will not modify a log multiple times in one day unless the criterium for that log is based on the log’s size". So, this means that even though cron runs hourly/daily/weekly, if I set a size parameter, cron settings will be ignored and the file will be rotated as soon as its size reaches, e.g., 10k.
I have the following in my logrotate.conf
but the maillog is not rotated, i.e., the touch /var/log/maillog
is not executed:
/var/log/maillog
{
missingok
notifempty
nocompress
size=10k
postrotate
touch /var/log/maillog
endscript
}
What is wrong here?