Hi, I just changed the motherboard of a centos 4.4 installation for a new one. this new one has a SIS chipset. Now when i boot from the hard disk i get a kernel panic (unable to find root, no hdd found , etc)
I have identified the module I need to load to make centos "see" the disks. Now the question is what do I need to modify in my existing installation, to tell centos to use the new sis module and to *not* use the old intel?
Thanks,
Erick Perez wrote:
Hi, I just changed the motherboard of a centos 4.4 installation for a new one. this new one has a SIS chipset. Now when i boot from the hard disk i get a kernel panic (unable to find root, no hdd found , etc)
Really?
I have identified the module I need to load to make centos "see" the disks. Now the question is what do I need to modify in my existing installation, to tell centos to use the new sis module and to *not* use the old intel?
I fully expect moving a hard drive containing from one box to another to just work*. I do it fairly regularly too.
* Within some limits; you need to have the right network drivers to hand and they need to get loaded, and that bit's a little problematic in some distros, and you have to find where to plug the network cables in. Getting X to work properly can be a little iffy too, particularly with certain Dells with Intel graphics. Anything with Intel graphics.
Can't really help you though, without seeing it.
You're m eyes: what do I see?
Hint, You should have a current Knoppix CD handy. Every sysadmin should, including Windows sysadmins.
Hi, I just changed the motherboard of a centos 4.4 installation for a new one. this new one has a SIS chipset. Now when i boot from the hard disk i get a kernel panic (unable to find root, no hdd found , etc)
To me it sounds like your kernels initrd is likely configured for lvm. You might want to try taking the initrd from the centos cd/dvd and using that instead, or try booting the kernel without the initrd parameter and hope it works :)
Or go into the initrd and edit it by hand. it's either a gzipped cpio archive, or a gzipped ext2/3 filesystem.
You may also get away with simply changing the boot device listed on the kernels command line. You did edit /etc/grub/menu.lst right?
-Maciej
Erick Perez wrote:
Hi, I just changed the motherboard of a centos 4.4 installation for a new one. this new one has a SIS chipset. Now when i boot from the hard disk i get a kernel panic (unable to find root, no hdd found , etc)
I have identified the module I need to load to make centos "see" the disks. Now the question is what do I need to modify in my existing installation, to tell centos to use the new sis module and to *not* use the old intel?
Thanks,
I recently had to do pretty much the same thing, i.e. moved a hard drive from an Intel-chipset-based box to an AND-64 box with an nVidia chipset. The error you are getting is probably because your initrd file does not contain the driver for hard drive controller on the new motherboard. This is pretty much expected if you are using SATA or SCSI drives and change motherboard chipsets or disk adapters.
The basic steps to fix this are (1) identify the required storage driver, (2) modify the modprobe.conf file to reflect that driver, and (3) rebuild the initial RAMdisk file. To do this you need to boot the first disk of your CentOS distribution disk in rescue mode.
As mentioned, boot the system up using the first disk of the distribution (or the DVD or the single-disk server CD). At the boot prompt, enter 'linux rescue'. Note the messages while it loads drivers and you should see it load the storage driver for your storage adapter (usually in a white box on a blue screen). You'll need this later. Don't bother starting the network interface yet, but do let it mount the existing CentOS installation.
If you didn't notice the driver loading, use the 'lsmod' command from the command prompt to get a list of loaded drivers. You should be able to figure it out from that.
Next change your default directory to /mnt/sysimage/etc and look at the file modprobe.conf. You should see a line with something like 'alias scsi_hostadapter {something}' that defines the primary SCSI/SATA adapter. You should substitute the driver for the disk drive controller for {something}. You might also comment out some of the other stuff, like USB controller or sound cards, but kudzu should take care of them later.
Next you need to rebuild the initrd file. You need to chroot to the mounted original installation by issuing the command 'chroot /mnt/sysimage'. Now issue the command 'cd /boot' to get to the correct directory. You should see the kernel and initrd files there. If not, something went wrong earlier on and you should retrace your steps.
You should now move the old initrd file out of the way use the mkinitrd command to rebuild the initrd file for the kernel you intend to boot. The format is:
mkinitrd {initrd filename} {kernel version}
If you are using kernel 2.6.9-42.0.10.EL, use 'mkinitrd initrd-2.6.9-42.0.10.EL.img 2.6.9-42.0.10.EL'. If you get an error stating the file already exists, just move the old one out of the way (mv initrd-2.6.9-42.0.10.EL.img initrd-2.6.9-42.0.10.EL.img.old) and rerun the mkinitrd command.
You are just about done now. Exit out of the chroot enviromnent using the 'exit' command, then do a clean shutdown of the rescue environment. Remove the CD, reboot the box, and you should get past the kernel panic. I would recommend that you bring the box up in single-user mode the first time just to make sure nothing gets started that might "belch" on you because of misconfigurations. Kudzu should run automatically and will probably mention that a LOT of hardware devices no longer exist, just tell it to delete their configuration and let it finish up. Once you get to the command prompt you can examine /etc/modprobe.conf to see the changes it made. If all your partitions appear to be mounted, reboot again and you should be good-to-go.
This is pretty general and I almost certainly have left out some details. Perhaps others on the list could fill in some of the blanks.
Hope that helps!
On Tuesday 03 April 2007, Erick Perez wrote:
Hi, I just changed the motherboard of a centos 4.4 installation for a new one. this new one has a SIS chipset. Now when i boot from the hard disk i get a kernel panic (unable to find root, no hdd found , etc)
I have identified the module I need to load to make centos "see" the disks. Now the question is what do I need to modify in my existing installation, to tell centos to use the new sis module and to *not* use the old intel?
It's quite simple, stuff that is needed to access the thingy the /-filesystem lives on needs to be in the initrd.img-file. So if your disk-controller needs driver xyz.ko then that needs to be in there.
The initrd.img-file is typically created with the mkinitrd command. mkinitrd, among other things, reads /etc/modprobe.conf to figure out which kernel modules to put into the new initrd.img-file.
So, you'll have to create a new initrd.img-file with mkinitrd after adding something like "alias scsi_hostadapter xyz" to your modprobe.conf. If you run mkinitrd with -v you'll get to see which drivers it includes.
Good luck, Peter