Where does logrotate save its own log

logrotate

I have logrotate running in an EC2 AWS machine rotating Apache logs. Once packed, Apache logs are saved into AWS S3 via s3fs. The problem is that I recently noticed that I didn't have logs rotated. In S3 I have old logs from day 48->60 but the 1->47 doesn't appear.

My question is: Where does logrotate save its own log? It's possible that I have some kind of problem with s3fs, but I need to know before I do anything. I tried to find somewhere the logs but I couldn't find it out.

Any idea?

Best Answer

logrotate does not log anything by default. normally it should be in your cron somewhere, for instance:

$ grep -r -- 'logrotate.conf' /etc/cron*
/etc/cron.daily/logrotate:/usr/sbin/logrotate /etc/logrotate.conf

You can either run that manually to see what is wrong, or redirect the logrotate output to a file in the above cron to see what happened next day.

Likely somewhere the config is incorrect and caused the logrotate run to break.

Related Topic