LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Kernel panic – not syncing (https://www.linuxquestions.org/questions/linux-newbie-8/kernel-panic-%96-not-syncing-419660/)

alfredo 02-26-2006 03:04 AM

Kernel panic – not syncing
 
I have the following errors in two computers:
kernel panic - not syncing : VFS : Unable to mount root fs on unnown-block (0,0)

Kernel panic – not syncing: Attempte to kill init!

---------------------
All the filesystems that I need is included in the kernel (not like modules)

Next the steps that I have used when compiling:

1. make mrproper
2. make menuconfig (I selected what I need)
or make defconfig (verifying that the filesystems exists),
I also attempted it
3. make all
4. make modules_install
5. make install
here they are generated a heap of things as:
in / boot: initrd-2.6.15.4.img System.map-2.6.15.4 vmlinuz-2.6.15.4
/ etc/lilo.conf or when I use
/ boot/grub/grub.config
if I place:
mkinitrd / boot/initrd-2.6.15.4.img 2.6.15.4
says :
/ boot/initrd-2.6.15.4.img already exists.
6. reboot.
-------------------------------------------------------
Next an extract of the grub.conf

title CentOS (2.6.15.4)
root (hd0,0)
kernel / vmlinuz-2.6.15.4 ro root=LABEL = / rhgb
initrd / initrd-2.6.15.4.img

title CentOS (2.6.13.4)
root (hd0,0)
kernel / vmlinuz-2.6.13.4 ro root=LABEL = / rhgb
initrd / initrd-2.6.13.4.img

title CentOS-4 i386 (2.6.9-11.EL) OLD
root (hd0,0)
kernel / vmlinuz-2.6.9-11.EL ro root=LABEL = / rhgb
initrd / initrd-2.6.9-11.EL.img
----------------------------------------------------
The lines that correspond CentOS-4....., they were created automatically when I installed the CentOS for the first time. and it works perfectly!!
I don't see why it is not this way with the lines generated automatically and after carrying out make install, I see that they are same the parameters.
pd:
The lines of the 2.6.13.4......
they were also created automatically, and from there the same error!!
------------------
I believed that the error was the version of the kernel, and I lowered the last one; the error persists

kevkim55 02-26-2006 04:28 AM

When you boot your system look carefully at the messages on the screen. Do you see the necessary modules being loaded and without any errors ? Do you see your hard disk being recognized ? Do you see the partitions being listed like hda1 hda2 hda3 <hda4> hda5 .......... etc ??
Can you make a note of the last few lines before the line kernel panic - ..... and post it here ?
As the kernel panic message says "Unable to mount root fs on unknow block", the kernel is not able to find the root device node so it can mount it and boot you into the linux system. There'z something missing which, is the cause for the device being not available.

This is you grub.conf file
Quote:

title CentOS (2.6.15.4)
root (hd0,0)
kernel / vmlinuz-2.6.15.4 ro root=LABEL = / rhgb
initrd / initrd-2.6.15.4.img
Do you notice the space between / and vmlinu.... and also between / and initrd..... and so between / and rhgb ? Is it that you typed them this way in your posting or this is how your grub.conf really is ? There should be no spaces. The correct version would be
Quote:

title CentOS (2.6.15.4)
root (hd0,0)
kernel /vmlinuz-2.6.15.4 ro root=LABEL = /rhgb
initrd /initrd-2.6.15.4.img
For a start, try changing the argument root=LABEL=/rhgb to root=/dev/hda1 and see if it works.

Emerson 02-26-2006 04:39 AM

Unable to mount root fs on unnown-block (0,0)

This error message implies kernel has no built-in disk controller support. Please review your kernel configuration.

alfredo 02-26-2006 07:40 PM

You excuse, for not transcribing correctly (the spaces).
I already told them those lines (in the grub.conf or in the lilo.conf) they were created alone, when executing the make install (kernel 2.6.13.4 and 2.6.15.4)
Already carry out the changes in the kernel that works perfectly :

title CentOS-4 i386 (2.6.9-11.EL) OLD
root (hd0,0)
kernel /vmlinuz-2.6.9-11.EL ro root=LABEL=/ rhgb
initrd /initrd-2.6.9-11.EL.img

I changed the arguments
root=LABEL=/rhgb to root=/dev/hda1 and later
I also proved with root=LABEL=/rhgb to root=/dev/sda1

and there is what happened here.




SCSI device sda: 20971520 512-byte hdwr sectors (10737 MB)
sda: asking for cache data failed
Sda: assuming drive cache: write through
sda: sda1 sda2 sda3 sda4 <sda5 sda6 sda7>
Attached scsi disk sda at scsi0, channel 0, id 0, lun 0
Loading jbd.ko module
Loading ext3.ko module
Creating root device
Mounting root filesystem
#VFS: Can’t find ext3 filesiystem on dev sda
mount: error 6 mounting ext3
mount: error 2 mounting none
Switching to new root
#WARNING: can’t access (null)
#exec of init ((null)) failed!!!:14
switchroot: mount failed: 22
umount /initrd/dev failed: 2
Kernel panic – not syncing: Attempted to kill init
----------------------------------------------------

#: it means what happened when I applied with spaces : root= /dev/sda1
As I have GRUB, in hot, I published again and to return to the above-mentioned. And it continues working (2.6.9-11).
-----------------------------------------------

I send you the fstab to see like we solve the problem.
# This file is edited by fstab-sync - see 'man fstab-sync' for details
LABEL=/ / ext3 defaults 1 1
LABEL=/boot /boot ext3 defaults 1 2
none /dev/pts devpts gid=5,mode=620 0 0
none /dev/shm tmpfs defaults 0 0
LABEL=/home /home ext3 defaults 1 2
none /proc proc defaults 0 0
none /sys sysfs defaults 0 0
LABEL=/usr /usr ext3 defaults 1 2
LABEL=/var /var ext3 defaults 1 2
LABEL=SWAP-sda7 swap swap defaults 0 0
/dev/hdc /media/cdrecorder auto pamconsole,fscontext=system_u:object_r:removable_t,exec,noauto,managed 0 0
/dev/fd0 /media/floppy auto pamconsole,fscontext=system_u:object_r:removable_t,exec,noauto,managed 0 0
/dev/sdb /media/ROMI_1GB vfat pamconsole,noatime,sync,fscontext=system_u:object_r:removable_t,exec,noauto,managed 0 0
----------------------------------------------

And the #fdisk
Disco /dev/sda: 10.7 GB, 10737418240 bytes
255 cabezas, 63 sectores/pista, 1305 cilindros
Unidades = cilindros de 16065 * 512 = 8225280 bytes
Disposit. Boot Start End Blocks Id System
/dev/sda1 * 1 13 104391 83 Linux
/dev/sda2 14 714 5630782+ 83 Linux
/dev/sda3 715 969 2048287+ 83 Linux
/dev/sda4 970 1305 2698920 5 Extendida
/dev/sda5 970 1096 1020096 83 Linux
/dev/sda6 1097 1223 1020096 83 Linux
/dev/sda7 1224 1287 514048+ 82 Linux swap
Disco /dev/sdb: 1048 MB, 1048576000 bytes
33 cabezas, 61 sectores/pista, 1017 cilindros
Unidades = cilindros de 2013 * 512 = 1030656 bytes

Disposit. Boot Start End Blocks Id System
/dev/sdb1 ? 952374 1222801 272185273 6f Desconocido
La partición 1 tiene distintos principios físicos/lógicos (¿no Linux?):
físicos=(361, 101, 36) lógicos=(952373, 5, 28)
La partición 1 tiene distintos finales físicos/lógicos:
físicos=(255, 115, 46) lógicos=(1222800, 21, 46)
La partición 1 no termina en un límite de cilindro.
/dev/sdb2 ? 667083 1054223 389657273 69 Desconocido
La partición 2 tiene distintos principios físicos/lógicos (¿no Linux?):
físicos=(100, 101, 32) lógicos=(667082, 2, 36)
La partición 2 tiene distintos finales físicos/lógicos:
físicos=(367, 115, 35) lógicos=(1054222, 30, 53)
La partición 2 no termina en un límite de cilindro.
/dev/sdb3 ? 83780 83780 0 20 Desconocido
La partición 3 tiene distintos principios físicos/lógicos (¿no Linux?):
físicos=(353, 117, 46) lógicos=(83779, 31, 51)
La partición 3 tiene distintos finales físicos/lógicos:
físicos=(355, 116, 37) lógicos=(83779, 31, 50)
La partición 3 no termina en un límite de cilindro.
/dev/sdb4 1433523 1433551 27619 0 Vacía
La partición 4 tiene distintos principios físicos/lógicos (¿no Linux?):
físicos=(0, 0, 0) lógicos=(1433522, 22, 25)
La partición 4 tiene distintos finales físicos/lógicos:
físicos=(0, 0, 0) lógicos=(1433550, 3, 57)
La partición 4 no termina en un límite de cilindro.
Las entradas de la tabla de particiones no están en el orden del disco
----------------------------------------------

And #mount
/dev/sda6 on / type ext3 (rw) [/]
none on /proc type proc (rw)
none on /sys type sysfs (rw)
none on /dev/pts type devpts (rw,gid=5,mode=620)
usbfs on /proc/bus/usb type usbfs (rw)
/dev/sda1 on /boot type ext3 (rw) [/boot]
none on /dev/shm type tmpfs (rw)
/dev/sda5 on /home type ext3 (rw) [/home]
/dev/sda2 on /usr type ext3 (rw) [/usr]
/dev/sda3 on /var type ext3 (rw) [/var]
none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw)
/dev/sdb on /media/ROMI_1GB type vfat (rw,nosuid,nodev,sync,noatime,fscontext=system_u:object_r:removable_t)
-----------------------------------------------------------

what we have to put, in the parameters of the 2.6.15.4 ?

alfredo 02-26-2006 07:45 PM

You excuse, for not transcribing correctly (the spaces).
I already told them those lines (in the grub.conf or in the lilo.conf) they were created alone, when executing the make install (kernel 2.6.13.4 and 2.6.15.4)
Already carry out the changes in the kernel that works perfectly :

title CentOS-4 i386 (2.6.9-11.EL) OLD
root (hd0,0)
kernel /vmlinuz-2.6.9-11.EL ro root=LABEL=/ rhgb
initrd /initrd-2.6.9-11.EL.img

I changed the arguments
root=LABEL=/rhgb to root=/dev/hda1 and later
I also proved with root=LABEL=/rhgb to root=/dev/sda1

and there is what happened here.




SCSI device sda: 20971520 512-byte hdwr sectors (10737 MB)
sda: asking for cache data failed
Sda: assuming drive cache: write through
sda: sda1 sda2 sda3 sda4 <sda5 sda6 sda7>
Attached scsi disk sda at scsi0, channel 0, id 0, lun 0
Loading jbd.ko module
Loading ext3.ko module
Creating root device
Mounting root filesystem
#VFS: Can’t find ext3 filesiystem on dev sda
mount: error 6 mounting ext3
mount: error 2 mounting none
Switching to new root
#WARNING: can’t access (null)
#exec of init ((null)) failed!!!:14
switchroot: mount failed: 22
umount /initrd/dev failed: 2
Kernel panic – not syncing: Attempted to kill init
----------------------------------------------------

#: it means what happened when I applied with spaces : root= /dev/sda1
As I have GRUB, in hot, I published again and to return to the above-mentioned. And it continues working (2.6.9-11).
-----------------------------------------------

I send you the fstab to see like we solve the problem.
# This file is edited by fstab-sync - see 'man fstab-sync' for details
LABEL=/ / ext3 defaults 1 1
LABEL=/boot /boot ext3 defaults 1 2
none /dev/pts devpts gid=5,mode=620 0 0
none /dev/shm tmpfs defaults 0 0
LABEL=/home /home ext3 defaults 1 2
none /proc proc defaults 0 0
none /sys sysfs defaults 0 0
LABEL=/usr /usr ext3 defaults 1 2
LABEL=/var /var ext3 defaults 1 2
LABEL=SWAP-sda7 swap swap defaults 0 0
/dev/hdc /media/cdrecorder auto pamconsole,fscontext=system_u:object_r:removable_t,exec,noauto,managed 0 0
/dev/fd0 /media/floppy auto pamconsole,fscontext=system_u:object_r:removable_t,exec,noauto,managed 0 0
/dev/sdb /media/ROMI_1GB vfat pamconsole,noatime,sync,fscontext=system_u:object_r:removable_t,exec,noauto,managed 0 0
----------------------------------------------

And the #fdisk
Disco /dev/sda: 10.7 GB, 10737418240 bytes
255 cabezas, 63 sectores/pista, 1305 cilindros
Unidades = cilindros de 16065 * 512 = 8225280 bytes
Disposit. Boot Start End Blocks Id System
/dev/sda1 * 1 13 104391 83 Linux
/dev/sda2 14 714 5630782+ 83 Linux
/dev/sda3 715 969 2048287+ 83 Linux
/dev/sda4 970 1305 2698920 5 Extendida
/dev/sda5 970 1096 1020096 83 Linux
/dev/sda6 1097 1223 1020096 83 Linux
/dev/sda7 1224 1287 514048+ 82 Linux swap
Disco /dev/sdb: 1048 MB, 1048576000 bytes
33 cabezas, 61 sectores/pista, 1017 cilindros
Unidades = cilindros de 2013 * 512 = 1030656 bytes

Disposit. Boot Start End Blocks Id System
/dev/sdb1 ? 952374 1222801 272185273 6f Desconocido
La partición 1 tiene distintos principios físicos/lógicos (¿no Linux?):
físicos=(361, 101, 36) lógicos=(952373, 5, 28)
La partición 1 tiene distintos finales físicos/lógicos:
físicos=(255, 115, 46) lógicos=(1222800, 21, 46)
La partición 1 no termina en un límite de cilindro.
/dev/sdb2 ? 667083 1054223 389657273 69 Desconocido
La partición 2 tiene distintos principios físicos/lógicos (¿no Linux?):
físicos=(100, 101, 32) lógicos=(667082, 2, 36)
La partición 2 tiene distintos finales físicos/lógicos:
físicos=(367, 115, 35) lógicos=(1054222, 30, 53)
La partición 2 no termina en un límite de cilindro.
/dev/sdb3 ? 83780 83780 0 20 Desconocido
La partición 3 tiene distintos principios físicos/lógicos (¿no Linux?):
físicos=(353, 117, 46) lógicos=(83779, 31, 51)
La partición 3 tiene distintos finales físicos/lógicos:
físicos=(355, 116, 37) lógicos=(83779, 31, 50)
La partición 3 no termina en un límite de cilindro.
/dev/sdb4 1433523 1433551 27619 0 Vacía
La partición 4 tiene distintos principios físicos/lógicos (¿no Linux?):
físicos=(0, 0, 0) lógicos=(1433522, 22, 25)
La partición 4 tiene distintos finales físicos/lógicos:
físicos=(0, 0, 0) lógicos=(1433550, 3, 57)
La partición 4 no termina en un límite de cilindro.
Las entradas de la tabla de particiones no están en el orden del disco
----------------------------------------------

And #mount
/dev/sda6 on / type ext3 (rw) [/]
none on /proc type proc (rw)
none on /sys type sysfs (rw)
none on /dev/pts type devpts (rw,gid=5,mode=620)
usbfs on /proc/bus/usb type usbfs (rw)
/dev/sda1 on /boot type ext3 (rw) [/boot]
none on /dev/shm type tmpfs (rw)
/dev/sda5 on /home type ext3 (rw) [/home]
/dev/sda2 on /usr type ext3 (rw) [/usr]
/dev/sda3 on /var type ext3 (rw) [/var]
none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw)
/dev/sdb on /media/ROMI_1GB type vfat (rw,nosuid,nodev,sync,noatime,fscontext=system_u:object_r:removable_t)
-----------------------------------------------------------

what we have to put, in the parameters of the 2.6.15.4 ?

kevkim55 02-27-2006 05:56 AM

The mount command's outpost in your last posting shows that the root filesystem resides on /dev/sda6. Change the root argument from root=/dev/sda1 to root=/dev/sda6 and tell me if this works for you.

BinJajer 02-27-2006 11:12 AM

Ok, I'm sure that it's not what happened, but worth mentioning anyways: The kernel in snot moved from another OS, as an image? Ok, having said that, try the gentoo-style way: append root=/dev/ram0 real_root=/dev/sda6 (or 1?)


All times are GMT -5. The time now is 06:05 AM.