New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature request: seamless compressor migration by deleting old files regardless of old compressor #526
Comments
How frequently do you change the compression algorithm? |
I think like 3 times so far in my life (gz->bz2->xz->zst) BUT that was only on few of my private machines to keep disk space usage as lowest possible. On most of machines I still use default gzip since beginning because changing to anything else means recompressing ~36 000 old log files on almost 100 machines (I keep year worth logs; rotated daily) which are about 2TB of data. If I ever decided to do that, like on my private machines, it would be these numbers x3. If this feature is problematic in implementation then well... but if it is easy enough then please consider implementing it to make switch easy and convenient for all people like me. |
There is no way to migrate from one compressor to another without having manually recompress old files (as far I know).
This feature request is about adding feature where logrotate will know which extensions
are considered to be still the same log.
Maybe:
So it will delete old logs, regardless which compressor was used from the list.
Example of current 3.21.0 behaviour:
Logrotate file:
Now we change from gzip to zstd (uncommenting zstd options from my example config)
logrotate never deletes old gzipped logs, only touching zst files.
Proposed feature would make switching between compressor easy, without having to recompress gigabytes of old logs.
The text was updated successfully, but these errors were encountered: