Nat! bio photo

Nat!

Senior Mull.

Twitter RSS

Github

Keep a complete history of apt-get calls

Linux does it right, as all the packages you install with apt-get are logged in /var/log/apt/history.log. If you want to know what you installed over time this is great.

Unfortunately for some reason both Debian and Ubuntu are doing it wrong, because they rotate these logs away. A year after installation I am losing my history.

So I edit the /etc/logrotate.d/apt file and throw out this setting:

/var/log/apt/history.log {
  rotate 12
  monthly
  compress
  missingok
  notifempty
}

Post a comment

All comments are held for moderation; basic HTML formatting accepted.

Name:
E-mail: (not published)
Website: