Ask Your Question

Preupgrade failed during reboot

asked 2011-11-09 23:06:48 -0500

libregeek gravatar image

updated 2011-11-10 00:40:03 -0500

mether gravatar image

I tried to upgrade my F15(x86_64) desktop to F16 through preupgrade and failed while rebooting. F15 uses LVM volumes, except for /boot.

The packages were successfully downloaded and the system prompted to reboot. After rebooting anaconda reported the following error in GUI:

The root for the previously installed system was not found

and the system prompted to exit the installer. When the installer exited, the following message was seen on the console:

error: cannot open Packages database in /mnt/sysimage/var/lib/rpm

Is this is a bug or am I doing something wrong?


It seems a bug in anaconda reported here: rhbz#748119 but the workaround mentioned there doesn't work.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2011-11-10 05:34:50 -0500

jfmchivall gravatar image

updated 2011-11-10 05:36:50 -0500

If this is rhbz#748119 (cannot upgrade if /var is on a separate volume to /), then the simplest way to solve this is using a live cd/usb or "rescue mode" on your install dvd/usb to copy the RPM database to the filesystem root.

  1. Boot install media and from the menu choose "Troubleshooting" and then "Rescue an installed system"
  2. You will end up at a shell prompt. The filesystem root of the currently installed system will be mounted at /mnt/sysimage/
  3. You need to mount your /var volume to somewhere outside the existing filesystem to be able to copy the RPM db over. For example, if /var is on a LVM logical volume called "VarVol" in volume group "MyVG", you would do:

# mount /dev/mapper/MyVG-VarVol /mnt/temporary_var

(If you were to mount it at /mnt/sysimage/var, then the /var volume would "overlay" the root volume, and you wouldn't easily be able to copy the files to the root volume.)

  1. Make the /var/lib/ directory in the root fs:

# mkdir -p /mnt/sysimage/var/lib

  1. Copy the RPM db into the new location:

# cp -rpvaf /mnt/temporary_var/lib/rpm /mnt/sysimage/var/lib/

  1. Reboot

# reboot

Now you should be able to upgrade your system! There are more comments on the bugtracker page, which might help if this doesn't work immediately for you.

edit flag offensive delete link more

Question Tools


Asked: 2011-11-09 23:06:48 -0500

Seen: 2,659 times

Last updated: Nov 10 '11