Articles

So if you're running CentOS as a Hyper-V guest you may have seen something like this after updating the kernel and your OS won't boot anymore. "Kernel panic - not syncing: Attempted to kill init!"

ic_update5

In order to fix this you'll need to reboot into the previous kernel that you installed the integration components to, and update the new kernel with the integration components drivers.  To get the integration components to install to a kernel that's not running you need to edit the following files to specifiy which kernel to install to.

/opt/integration_services/Makefile
/opt/integration_services/scripts/updategrub.pl
/opt/integration_services/scripts/updateinitrd.pl
/opt/integration_services/scripts/determine_os
/opt/integration_services/src/Makefile

Anything in these files that says shell uname -r needs to be replaced with shell echo "2.6.18-194.26.1.el5" use the new kernel version between the quotes.

Anything in these files that says `uname -r` needs to be replaced with "2.6.18-194.26.1.el5" use the new kernel version between the quotes.

 

Reboot the system and when prompted hit a key to get the below menu. Select the last kernel you know to have worked. Also write down the new kernel version number, we'll need it when editing the scripts.

ic_update6

Change directories to wherever you have the linux integration components install files, in my case /opt/integration_services. To find the files you need to edit run # grep -iR "uname -r" *

ic_update7

Now start editing the scripts... first one is the Makefile, there's 3 spots that need to be changed in this file, screenshots only show the first two.

Before

ic_update8

After

ic_update9

Next is scripts/updategrubconf.pl

Before

ic_update10

After

ic_update11

scripts/updateinitrd.pl

Before

ic_update18

After

ic_update19

scripts/determine_os

Before

ic_update12

After

ic_update13

 src/Makefile

Before

ic_update20

After

ic_update21

Now run # make  

ic_update14

 # make install

ic_update15

 Now reboot and let it start the new kernel.  It should load up fine.

ic_update17

Category: Virtualization