CentOS 5 Hyper-V VM Won't Boot After Integration Services Removal← Back

I had a CentOS 5 Hyper-V VM running on Windows 2012 / Hyper-V 3.0 on which I mistakenly installed the Linux Integration Services 3.4 using the RHEL57 packages. The installation completed with some warnings and the initial reboot was OK, but after removing the "microsoft-hyper-v" and then "kmod-microsoft-hyper-v" packages the VM would no longer boot due to a kernel panic.
The kernel panic message was:
switchroot: mount failed: No such file or directory Kernel panic - not syncing: Attempted to kill init!
- I booted from the CentOS 5 installation CD #1 and entered "linux rescue" at the "boot:" prompt to enter rescue mode.
- I selected the default language options.
- I chose not to start networking services, as they were not required.
- I selected the Continue button to mount the filesystem under /mnt/sysimage
- I modified /mnt/sysimage/boot/grub/grub.conf
- The existing kernel line was similar to
kernel /vmlinuz-2.6.18-194.el5 ro root=/dev/VolGroup00/LogVol00 noprobe=hda1 noprobe=hda2
- I modified it to
kernel /vmlinuz-2.6.18-194.el5 ro root=/dev/VolGroup00/LogVol00
After rebooting, the server booted successfully.
The real solution for older CentOS 5 and RHEL 5 VMs is that you need to download Linux Integration Services 2.1 and install it.
If you didn't install the Development Tools group during initial installation, you'll likely need to remove the Hyper-V VM network adapter and add a Legacy Adapter to enable network connection.
Comments
Jack Veton
2014-05-28
Thanks to your great solution, I have could solve my problem :-)
Thank you to people like you, who share your knowledge.
Marc Y Ruben
2014-02-27
You save our asses
Jonathan
2013-12-09
Glad to hear my blog post helped!