On 08/04/12 11:40, James Courtier-Dutton wrote:
> After reading the "crippled system" thread, I think it might be a good
> idea if Linux was able to do transaction based upgrades.
> In that thread, what happened is the user space udev package got
> upgraded, and the matching kernel package did not.
> I think it would have been better if udev would not upgrade itself
> unless a compatible kernel also managed to upgrade.
> I.e. Both in one transaction.

The fs-snapshot Yum plugin can give you the ability to rollback from a
broken upgrade.  On Fedora it's in the yum-plugin-fs-snapshot package.

There's a decent description of the process in the RHEL 6 docs:
http://docs.redhat.com/docs/en-US/Red_Hat_Enterprise_Linux/6/html/Deployment_Guide/sec-Plugin_Descriptions.html

The idea is it simply creates an LVM snapshot (so block level) which you
can remove again after the upgrade has been proven to be successful.  If
it fails, then you use the newish dm snapshot merge functionality which
"merges" the snapshot back into the origin, effectively rolling it back.
 This is just a case of running:
  lvconvert --merge /dev/yourvg/yourlv-snapshot

Because it's on the root volume, you reboot and it'll be reverted.

The catch is you need free space in the LVM VG to create the snapshot in
the first place, so leave 10% or something free.  This is used for
recording changes made while the snapshot exists.

For other distros you can just create the snapshot manually or use a
hook if available, there's no specific functionality needed in the
plugin or package manager.

-- 
Dominic Cleal
domi...@computerkb.co.uk

--
Please post to: Hampshire@mailman.lug.org.uk
Web Interface: https://mailman.lug.org.uk/mailman/listinfo/hampshire
LUG URL: http://www.hantslug.org.uk
--------------------------------------------------------------

Reply via email to