SysAdmin | sys·ad·min | noun - A system administrator. The duties of a system administrator are wide-ranging, and vary widely from one organization to another. Sysadmins are usually charged with installing, supporting, and maintaining servers or other computer systems, and planning for and responding to service outages and other problems.

RPM Rollbacks

on Nov 24, 2011 | Notes-to-self | 3241 comments

I've never been sure why this is not enabled by default, it should be among the first things I do when setting up a new server.

Add tsflags=repackage to /etc/yum.conf
Add %_repackage_all_erasures 1 to /etc/rpm/macros
If /etc/rpm/macros doesn't exist, just create it.

You can now install, erase and update packages with yum and/or rpm - if anything goes wrong, roll back to previous versions like this:

rpm -Uvh --rollback 'november 11'
rpm -Uvh --rollback '3 hours ago'
rpm -Uvh --rollback 'yesterday'
rpm -Uvh --rollback '13:00'