Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a daily logrotate set up with compress, missingok, delaycompress, dateext options. I need to compress the delayed log file. Can I do it manually now or should I wait till logrotate does it when it runs.

I'm just not sure whether logrotate has some internal storage, will it get confused if it'll see the file already compressed?

share|improve this question
up vote 2 down vote accepted

If I remember correctly, logrotate only uses the file names in the rotation and only the name will be changed if you compress the file. It won't even care for the file contents once they are rotated (if even before). You should be able to compress a file freely, but if you do it somehow differently, you may end up with that file out of the rotation just lying around in the directory.

Either way, I believe there is no harm in trying. It should be impossible to "confuse" logrotate.

share|improve this answer
Thanks - I shall just compress it and make the filename as other compressed files. – rATRIJS Mar 2 '12 at 11:23

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.