Hard time upgrading to Fedora 18

Hard time upgrading to Fedora 18

Upgrade to new version of Fedora (Fedora 18) was this time harder than french kissing an Anaconda. Both recommended methods of installing (USB from ISO) / upgrading (FedUp) failed for me.

Using FedUp is nightmare. It required in my case 3GB for download just to copy it to install directory (another 3GB). Even when I was able to empty that much space in the system partition it asked for another 2GB of empty space for the upgrade. After cleaning up the unnecessary stuff it still crashed in infinite loop asking for password for my encrypted drive (probably bug 896010).

Then I decided just delete the system partition and just make fresh install of it. Booting from the ISO image using USB / HDD grub2 loopback was quite ok. Problem is I was not able to pass through disk partitioning. I have got quite unusual partition table with multiboot to 3+ systems. All partitions are encrypted - truecrypt NTFS, LUKS + ext3, LUKS + swap, LUKS + LVM - probably some of that crypto stuff is freaking Anaconda do death. (bugs 890881 and/or 862948 )

My workaround to upgrade Fedora 17 to Fedora 18 with all the encryption was this:

  • boot from ISO CD / USB
  • use cryptsetup luksOpen for the system partition
  • format /dev/mapper/luks-root with mkfs -t ext4 to clean it
  • Clone the minimal filesystem on the ISO to your new system partition. The image of the minimal FC18 filesystem is as device mapped somewhere in /dev/mapper/*. Pipe "dump" command to "restore" to clone the whole filesystem. Someting like:
    dump -0u /dev/mapper/iso-min-something | (cd /mnt/root; restore -rf -)
  • mount the luks-root to /mnt/root directory and use yum --installroot=/mnt/root to install updated kernel
  • copy vmlinuz and initrd files to /boot partition
  • copy old fedora 17 record from /boot/grub2/grub.cfg to new one and update with the new fc18 version of kernel
  • change the UUID of the root partition in the grub record. Use "ls -l /dev/disk/by-uuid/" and "ls -l /dev/mapper/" to determine the UUID of the partition on the LUKS encrypted volume.
  • reboot
  • just for the case reinstall grub2 package "yum reinstall grub2"
  • yum -y update

No comments:

Post a Comment