Fedora 16 to 17 upgrade

I finally had the opportunity to upgrade my laptop from Fedora 16 to 17. When I installed 16 originally, within the week 17 came out, and I was too busy to do anything about it. Granted now 18 is in beta, and is likely to be released tomorrow now that I’ve done this upgrade, I wanted to post about an issue that I came across that no one seems to have touched on much, or at least there’s no real mention of it online. Only by chance did using a couple of tricks combined sort the problem out.

The problem I speak of is the preupgrade tool completing the job successfully, and then failing to boot after. I think the problem lies in the fact that it replaces grub with a newer version, fiddles with symlinks into /usr (e.g; /lib is now /usr/lib, etc, and symlinks are made for backward compatibility reasons), and perhaps doesn’t install the kernel correctly.

Here’s what happened. I installed preupgrade, and allowed it to go through the motions of downloading everything to my hard disk, and let it reboot. At first, it puzzled me because it just booted back into Fedora 16. But I rebooted it again, this time while I was watching it, and the “Upgrade to Fedora 17″ option in grub, while at the top, isn’t selected by default, so grub will naturally auto-boot the selected one, which is your previous installation. This is documented, somewhere, but not something you’d normally go looking for to begin with.

Secondly, preupgrade takes forever. Seriously, go get a coffee. Then get another one. Do the laundry, feed the kids, go on a picnic. It downloaded 1.6Gb of stuff on my machine, and I was running a fully up to date Fedora 16 install.

However, when it completes, the problems arise. A few errors popped up here and there, I forget exactly what they were, but they seemed unimportant (and actually were, so I won’t mention anything). The main problem was that it would hang on boot up. The Windows 2000-esq loading bar would stream along the bottom of the screen fairly quickly (nvidia kernel, not nouveau, so not the fancy splash boot loader for me), then drop back to a RHEL/Centos “starting up” view, where it lists services being started ok or failed. It’s there where it stopped. One on occasion, it hung starting sendmail, then I forced reboot and it hung a little later in the process. So, crazy thing here is that you can still boot your old fc16 kernels, so reboot, and select your next-oldest kernel (or newest fc16-labelled kernel) from the grub boot list, and boot that. Then, this is essentially what I did;

Find your exact kernel version by running

rpm -qa | grep kernel-

My output was:

kernel-devel-3.4.9-2.fc16.x86_64
kernel-devel-3.5.4-1.fc17.x86_64
kernel-headers-3.5.4-1.fc17.x86_64
kernel-3.4.9-2.fc16.x86_64
kernel-3.4.7-1.fc16.x86_64
kernel-devel-3.4.7-1.fc16.x86_64
kernel-3.5.4-1.fc17.x86_64

Find your latest (or only) fc17 kernel in there, and that’s the version you need. Then;

sudo yum erase kernel-3.5.4-1.fc17.x86_64
sudo yum install kernel-3.5.4-1.fc17.x86_64

Now, reboot, and see if that works. If it does, awesome. It didn’t for me. So next step, download the Fedora 17 NetInstall CD, and burn it to disc. The full CD isn’t necessary, as it doesn’t actually download anything. Boot into the installer, and let it find your Fedora install (it’ll be labelled Fedora 17, obviously), and tell it to upgrade it. The installer will sit there and think about it for a while, but it won’t actually download any packages, as it’ll realise that everything is now up to date. My guess here is that the installer re-configures something that preupgrade broke, or didn’t do.

Rebooting after the installer finished fiddling around, and I got my brand spanking new/upgraded Fedora 17 install.

Fedora 17 default desktop

And that’s all there is to it. At least, I hope! I’ve not found any other issues with it so far, it seems to be working as well as I’d expect it to be. No bugs or issues yet!