Unlimited Logs with Logrotate

Is there a way to set an unlimited number of potential logs in the regular logrotate.d configuration file?

The only thing I can think of is to set it to some insane number that will never be executed. Sort of:

/var/log/app/* {
  missingok
  weekly
  copytruncate
  rotate 10000000000
  compress
  notifempty
  olddir /var/log/app/old
}

But that seems pretty hoarse to me.

+5
source share
1 answer

From the logrotate UNIX management page :

speed

Log files are rotated before being deleted or mailed to the address specified in the mail directive. If count is 0, old versions are removed and then rotated.

So, I think you need to write a huge amount to work.

+3
source

All Articles