[Article Proposal] Use LVM to system-upgrade a Fedora server with minimal downtime

Current draft here: http://h.ssb.gathman.org/files/server-upgrade.html (need Cjdns installed to connect)

Excerpt: This article shows one way to upgrade a Fedora server using DNF along with Logical Volume Management (LVM) to keep a bootable backup in case of problems, and minimize downtime. This example upgrades a Fedora 33 virtual machine host to Fedora 35.

This example assumes you already have libvirt, qemu-kvm, partclone, and python3-dnf-plugin-system-upgrade installed. You must have enough memory available (2G recommended but I have succeeded with 1G) to create an additional virtual machine to run the upgrade. Your system can continue to operate while you prepare for and download the upgrade, and while the upgrade runs. Before you start, ensure your existing system is fully updated.

2 Likes

Sounds good to me. +1

+1 from me, as well. I’ve created Taiga card #398 for this article and assigned it to you.
When you start moving it into WordPress please set the status of the card to “In Progress” to let us know and when it is ready for review change it to “review”.

Thanks for volunteering to add to the Magazine.

I’m testing a similar process on a laptop with btrfs, but no LVM. The root fs will be btrfs sent to loopback or a usb drive, the upgrade run in a virtual machine, the upgraded fs btrfs sent back to a new subvol, and booting updated. This should probably be a followup article. It would be too confusing, I think, to try to cover both alternatives in the same article.

The selling point for the btrfs method is that you/your wife/SO can continue cranking away at writing (or whatever they do on Fedora) while you do most of the upgrade in the background in a VM.

In fact, the upgrade could run in a container in a subvol/directory. I really think Fedora should make this a supported upgrade method.

2 Likes

This is super interesting to me because my home server has lots of ram (64G) and lots of storage (3T Raid5) but a very small boot disk!

TIL about cjdns, so I’m looking forward to reading the article.

It’s already published: Use LVM to system-upgrade a Fedora Linux server with minimal downtime - Fedora Magazine :slightly_smiling_face: