Configuring logrotate for yum

Every time you use yum to install and/or update packages, it logs to /var/log/yum.log. A lot of people don't want to rotate the file a lot as they believe (incorrectly) that it is their only source to the history of their yum tasks. They may even believe that it provides a way to restore your rpm database if it gets corrupted - it does not.

I do recommend keeping your complete yum history as it doesn't grow a lot, unless you reinstall packages a lot.

For a rich interface to your yum history, I suggest you use yum history.

By default, your yum log file is rotated yearly, and even then, it only rotates if the size of your log file exceeds 30 KB, and your logs are only kept for 4 years. Usually, this is enough in the physical ...

Get Red Hat Enterprise Linux Server Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.