Kernel panic – not syncing: VFS: Unable to mount root fs on unknown block(0,0)

This is how to resolve the following error I encountered while upgrading Fedora 16 (EOL) to Fedora 17 using yum:

Loading Fedora (3.8.12-100.fc17.i686)
Kernel panic – not syncing: VFS: Unable to mount root fs on unknown block(0,0)
Pid: 1, comm: swapper/0 Not tained 3.8.12-100.fc17.i686 #1

The error and resolution are nearly identical to the Kernel panic – not syncing: VFS: Unable to mount root fs on unknown-block(0,0) I encountered three years ago upgrading Fedora 13 to 14.

I encountered the error upgrading Fedora to 16 to Fedora 17 after following the instructions according to the instructions on the Fedora wiki. After running yum –releasever=17 –disableplugin=presto distro-sync, I walked away. When I came back, the system automatically rebooted and had the error on the screen after trying to boot the Fedora 17 kernel:

Kernel panic - not syncing: VFS: Unable to mount root fs on unknown block(0,0)

Kernel panic – not syncing: VFS: Unable to mount root fs on unknown block(0,0)

This is how I solved the problem: First, I rebooted into the old Fedora 16 kernel where the GUI came up normally. I logged in as myself, switched to root, and ran these commands:

# This command shows many duplicate packages
# (the same packages for fc16 and fc17).
rpm -qa | sort

# Update a few packages missed the first time.
# Here yum complained about duplicate packages.
yum --releasever=17 --disableplugin=presto distro-sync

# This command removed 465 duplicates.
package-cleanup --cleandupes

# This found no problems.
package-cleanup --problems

# Remove new kernel
rpm -q kernel |grep fc17 | xargs rpm -e

# Reinstall new kernel
# Here I got the following error, which apparently was harmless.
# "grubby fatal error: unable to find a suitable template"
yum upgrade

# These commands are from the following URL
# https://fedoraproject.org/wiki/Upgrading_Fedora_using_yum#5._Make_sure_Fedora_is_upgraded
/usr/sbin/grub2-install /dev/sda 
cd /etc/rc.d/init.d; for f in *; do [ -x $f ] && /sbin/chkconfig $f resetpriorities; done
package-cleanup --orphans 

Then I rebooted into Fedora 17, and the system works fine.

Leave a comment