# Fresh install - kernel panic not syncing

## Bobr

Hi, I am new to Gentoo. I tried to install Gentoo on my old computer using Gentoo Handbook. At the end of proces I tried to boot the system, but there appeared: "end Kernel panic - not syncing: VFS: Unable to mount foot fs on unknown-block(8,3)".

I tried to find the solution in this forum, but I was unsucessful.

My fstab:

```
/dev/sda1     /boot         ext2      noauto,noatime 1 2

/dev/sda3     /             ext3      noatime        0 1

/dev/sda2     none          swap      sw             0 0

/dev/cdrom    /mnt/cdrom    auto      noauto,ro      0 0

/dev/fd0      /mnt/floppy   auto      noauto         0 0

```

Lilo (GRUB did not work):

```
boot=/dev/sda

prompt

timeout=50

default=gentoo

image=/boot/vmlinuz-4.1.12-gentoo

  label=gentoo

  read-only

  root=/dev/sda3

image=/boot/vmlinuz-4.1.12-gentoo

  label=gentoo.rescue

  read-only

  root=/dev/sda3

  append="init=/bin/bb"

```

It is x86 architecture.

Which additional information should I provide?

Thanks a lot.

Bobr

----------

## TigerJr

partition gpt or dos? and filesystem drivers in kernel .config ...

----------

## Aquous

Does your kernel have ext3 support compiled in (not as module)?

----------

## NeddySeagoon

Bobr,

Welcome to Gentoo.

```
unknown-block(8,3)
```

is very informative.

The 8,3 is the major, minor kernel device numbers.  That you get 8,3 and not 0,0 ol 1,0 tells that the kernel can see /dev/sda3 but not read what it finds there.

That can is because /dev/sda3 is not using a file system that the kernel understands.

As Aquous suggets, it may be missing from the kernel.

Maybe you have more that one HDD connected an the kernel is looking at the wrong drive?

You are not loading an initrd in your lilo.conf.  That's OK providing no kernel modules are needed to mount root.

----------

## Bobr

Thanks for answering.

 *TigerJr wrote:*   

> partition gpt or dos? and filesystem drivers in kernel .config ...

 

Partition is dos. 

Filesystems:

```
# File systems

#

CONFIG_DCACHE_WORD_ACCESS=y

CONFIG_EXT2_FS=y

CONFIG_EXT2_FS_XATTR=y

CONFIG_EXT2_FS_POSIX_ACL=y

CONFIG_EXT2_FS_SECURITY=y

CONFIG_EXT3_FS=y

CONFIG_EXT3_DEFAULTS_TO_ORDERED=y

CONFIG_EXT3_FS_XATTR=y

CONFIG_EXT3_FS_POSIX_ACL=y

CONFIG_EXT3_FS_SECURITY=y

# CONFIG_EXT4_FS is not set

CONFIG_JBD=y

CONFIG_JBD_DEBUG=y

CONFIG_FS_MBCACHE=y

# CONFIG_REISERFS_FS is not set

# CONFIG_JFS_FS is not set

# CONFIG_XFS_FS is not set

# CONFIG_GFS2_FS is not set

# CONFIG_BTRFS_FS is not set

# CONFIG_NILFS2_FS is not set

# CONFIG_F2FS_FS is not set

# CONFIG_FS_DAX is not set

CONFIG_FS_POSIX_ACL=y

CONFIG_EXPORTFS=y

CONFIG_FILE_LOCKING=y

CONFIG_FSNOTIFY=y

CONFIG_DNOTIFY=y

CONFIG_INOTIFY_USER=y

# CONFIG_FANOTIFY is not set

CONFIG_QUOTA=y

CONFIG_QUOTA_NETLINK_INTERFACE=y

# CONFIG_PRINT_QUOTA_WARNING is not set

# CONFIG_QUOTA_DEBUG is not set

CONFIG_QUOTA_TREE=y

# CONFIG_QFMT_V1 is not set

CONFIG_QFMT_V2=y

CONFIG_QUOTACTL=y

CONFIG_AUTOFS4_FS=y

# CONFIG_FUSE_FS is not set

# CONFIG_OVERLAY_FS is not set
```

Whole kernel.config is here: https://bpaste.net/show/98ea1ccfebf0

Thanks for help

Bobr

----------

## Bobr

Thanks for answering.

 *Aquous wrote:*   

> Does your kernel have ext3 support compiled in (not as module)?

 

I think I have got an ext2 and ext3 support. But maybe I did something wrong.

Here is my kernel.config:

https://bpaste.net/show/98ea1ccfebf0

Thanks for any help

Bobr

----------

## Bobr

Hi, NeddySeagoon,

thanks for answering.

 *NeddySeagoon wrote:*   

> Bobr,
> 
> Welcome to Gentoo.
> 
> ```
> ...

 

I think, I have an ext3 support, If I did it correctly. (Kernel.config: https://bpaste.net/show/98ea1ccfebf0)

 *Quote:*   

> Maybe you have more that one HDD connected an the kernel is looking at the wrong drive?

 

I have got only one HDD.

 *Quote:*   

> You are not loading an initrd in your lilo.conf.  That's OK providing no kernel modules are needed to mount root.

 

I will look more on this possibility.

Thanks for help

Bobr

----------

## TigerJr

 *Bobr wrote:*   

> 
> 
> I think, I have an ext3 support, If I did it correctly. (Kernel.config: https://bpaste.net/show/98ea1ccfebf0)
> 
> 

 

It's correct for ext3, maybe you are using ext4 or other filesystem. Or in lilo.conf root=/dev/sda3 is not a root filesystem!

----------

## NeddySeagoon

Bobr,

Do you have a USB storage device attached when the boot fails?

If so, unplug it and try again.

----------

## Bobr

 *NeddySeagoon wrote:*   

> Bobr,
> 
> Do you have a USB storage device attached when the boot fails?
> 
> If so, unplug it and try again.

 

I haven't got anything attached in USB. I've got only two mechanics for DVD, one for floppy disc (all of them empty). I cannot find problem in hardware, but maybe there is. (For example it was impossible to compile kernel with 64-bit kernel option.)

Regards,

Bobr

----------

## NeddySeagoon

Bobr,

Lets start with all the basics.

Post your lspci output.

Use wgetpaste to put your kernel .config onto a pastebin site. Tell us the link.

Mount your gentoo at /mnt/gentoo but do not chroot.

Post the output of 

```
df -T
```

We already have your /etc/fstab but that's not been used yet.

Post your grub.gfg

----------

## Bobr

 *TigerJr wrote:*   

>  *Bobr wrote:*   
> 
> I think, I have an ext3 support, If I did it correctly. (Kernel.config: https://bpaste.net/show/98ea1ccfebf0)
> 
>  
> ...

 

I have included ext4 in kernel before reporting this problem here and it still didn't work (same error), so I tried to remove ext4 from kernel, if it would not be better. I'm pretty sure I haven't use other filesystems then ext2-4.

 *Quote:*   

> Or in lilo.conf root=/dev/sda3 is not a root filesystem!

 

I made root on sda3 using fdisc, but maybe lilo use different numbering. This is the first time I work with it.

Thanks for help

Bobr

----------

## NeddySeagoon

Bobr,

Your problem is not boot loader related. The message 

```
Kernel panic - not syncing: VFS: Unable to mount foot fs on unknown-block(8,3)
```

 comes from the kernel.  For that to happen, the boot loader has found the kernel, loaded it and the kernel is running.

The boot loaders job is over.

lilo is a bit of an oddity among boot loaders.  At boot time, it closes its eyes and reads a block list without regards to what the blocks actually contain.

Hopefully its your kernel.  lilo does not read the boot filesystem to find the kernel.

Its essential that you run /sbin/lilo every time you change lilo.conf or the contents of /boot, so the boot time block list is updated.

lilo is quite happy to load a kernel from file system free space.

----------

## Bobr

 *NeddySeagoon wrote:*   

> Bobr,
> 
> Lets start with all the basics.
> 
> Post your lspci output.
> ...

 

My lspci:

```
00:00.0 Host bridge: VIA Technologies, Inc. VT8366/A/7 [Apollo KT266/A/333]

00:01.0 PCI bridge: VIA Technologies, Inc. VT8366/A/7 [Apollo KT266/A/333 AGP]

00:06.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL-8100/8101L/8139 PCI Fast Ethernet Adapter (rev 10)

00:08.0 Multimedia audio controller: Creative Labs SB Live! EMU10k1 (rev 07)

00:08.1 Input device controller: Creative Labs SB Live! Game Port (rev 07)

00:09.0 USB controller: VIA Technologies, Inc. VT82xx/62xx UHCI USB 1.1 Controller (rev 61)

00:09.1 USB controller: VIA Technologies, Inc. VT82xx/62xx UHCI USB 1.1 Controller (rev 61)

00:09.2 USB controller: VIA Technologies, Inc. USB 2.0 (rev 63)

00:11.0 ISA bridge: VIA Technologies, Inc. VT8233 PCI to ISA Bridge

00:11.1 IDE interface: VIA Technologies, Inc. VT82C586A/B/VT82C686/A/B/VT823x/A/C PIPC Bus Master IDE (rev 06)

00:11.2 USB controller: VIA Technologies, Inc. VT82xx/62xx UHCI USB 1.1 Controller (rev 1b)

00:11.3 USB controller: VIA Technologies, Inc. VT82xx/62xx UHCI USB 1.1 Controller (rev 1b)

00:11.4 USB controller: VIA Technologies, Inc. VT82xx/62xx UHCI USB 1.1 Controller (rev 1b)

01:00.0 VGA compatible controller: NVIDIA Corporation NV11 [GeForce2 MX/MX 400] (rev b2)
```

kernel.config: https://bpaste.net/show/5ff5d0568087

df -T:

```
Filesystem     Type     1K-blocks    Used Available Use% Mounted on

/dev           none         10240       4     10236   1% /mnt/gentoo/dev

tmpfs          tmpfs       126596   62492     64104  50% /

/dev/loop0     squashfs    182656  182656         0 100% /mnt/livecd

/dev/sr0       iso9660     209772  209772         0 100% /mnt/cdrom

tmpfs          tmpfs        25320     452     24868   2% /run

shm            tmpfs       126596       0    126596   0% /dev/shm

cgroup_root    tmpfs        10240       0     10240   0% /sys/fs/cgroup

tmpfs          tmpfs       126596       0    126596   0% /mnt/livecd/usr/portage

/dev/sda3      ext3      37729376 4142964  31663160  12% /mnt/gentoo

/dev/sda1      ext2        126931   19867    100511  17% /mnt/gentoo/boot
```

lilo.conf:

```
boot=/dev/sda

prompt

timeout=50

default=gentoo

image=/boot/vmlinuz-4.1.12-gentoo

  label=gentoo

  read-only

  root=/dev/sda3

image=/boot/vmlinuz-4.1.12-gentoo

  label=gentoo.rescue

  read-only

  root=/dev/sda3

  append="init=/bin/bb"
```

I can try install grub instead of lilo, if it helps.

Thanks for help.

Bobr

----------

## NeddySeagoon

Bobr,

Your boot loader won't make any difference. Both work.  lilo needs a bit more care than grub is all.

```
Filesystem     Type     1K-blocks    Used Available Use% Mounted on 

/dev/sda3      ext3      37729376 4142964  31663160  12% /mnt/gentoo

/dev/sda1      ext2        126931   19867    100511  17% /mnt/gentoo/boot
```

You need ext3 in the kernel to boot. ext2 is useful to be able to update the content of /boot. 

Your HDD is attached to 

```
00:11.1 IDE interface: VIA Technologies, Inc. VT82C586A/B/VT82C686/A/B/VT823x/A/C PIPC Bus Master IDE (rev 06)
```

and you are not using an initrd.

I should have asked if you are using an MSDOS or GPT partition table.  I will assume MSDOS for now.

Both are in the kernel anyway

```
CONFIG_MSDOS_PARTITION=y

CONFIG_EFI_PARTITION=y
```

The high level SCSI drivers and the transport ... good

```
CONFIG_SCSI=y

CONFIG_BLK_DEV_SD=y

CONFIG_BLK_DEV_SR=y

CONFIG_ATA=y
```

Going through the low level things

```
CONFIG_ATA_BMDMA=y

# CONFIG_PATA_VIA is not set
```

That CONFIG_PATA_VIA is not set is a problem.  Its the low level driver for your IDE chipset.

You need CONFIG_PATA_VIA=Y

Looking at filesystems

```
CONFIG_EXT2_FS=y

CONFIG_EXT3_FS=y

# CONFIG_EXT4_FS is not set

CONFIG_ISO9660_FS=y

CONFIG_JOLIET=y

CONFIG_ZISOFS=y

CONFIG_FAT_FS=y

CONFIG_MSDOS_FS=y

CONFIG_VFAT_FS=y
```

is all good.  Only ext3 is needed to boot.

Rebuild and reinstall your kernel. Set  CONFIG_PATA_VIA=Y in menuconfig. Press / and enter PATA_VIA to discover where it is.

Don't forget to run /sbin/lilo before you reboot.

Your error message, with the (8,3) is unusual.  With the low level driver missing, its normally (0,0)

----------

## TigerJr

 *Bobr wrote:*   

> 
> 
> 00:11.1 IDE interface: VIA Technologies, Inc. VT82C586A/B/VT82C686/A/B/VT823x/A/C PIPC Bus Master IDE (rev 06)
> 
> 

 

You have conflict with the IDE device drivers those make node like /dev/hda

Try to use lilo root=/dev/hda3 option =) Or recompile kernel without deprecated drivers support (if i don't forget sommething)...

Choose from:

# CONFIG_SATA_VIA is not set

# CONFIG_PATA_VIA is not set

----------

## Bobr

Enabling PATA_VIA change nothing. There is still the 8,3 kernel panic  :Sad: 

 *TigerJr wrote:*   

>  *Bobr wrote:*   
> 
> 00:11.1 IDE interface: VIA Technologies, Inc. VT82C586A/B/VT82C686/A/B/VT823x/A/C PIPC Bus Master IDE (rev 06)
> 
>  
> ...

 

Using hda instead of sda, after /sbin/lilo:

```

Warning: LBA32 addressing assumed

Fatal: raid_setup: stat("/dev/hda")
```

lspci -k:

```

00:00.0 Host bridge: VIA Technologies, Inc. VT8366/A/7 [Apollo KT266/A/333]

        Subsystem: VIA Technologies, Inc. VT8366/A/7 [Apollo KT266/A/333]

lspci: Unable to load libkmod resources: error -12

00:01.0 PCI bridge: VIA Technologies, Inc. VT8366/A/7 [Apollo KT266/A/333 AGP]

00:06.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL-8100/8101L/8139 PCI Fast Ethernet Adapter (rev 10)

        Subsystem: Realtek Semiconductor Co., Ltd. RTL-8100/8101L/8139 PCI Fast Ethernet Adapter

        Kernel driver in use: 8139too

00:08.0 Multimedia audio controller: Creative Labs SB Live! EMU10k1 (rev 07)

        Subsystem: Creative Labs SBLive! 5.1 Model SB0100

        Kernel driver in use: snd_emu10k1

00:08.1 Input device controller: Creative Labs SB Live! Game Port (rev 07)

        Subsystem: Creative Labs Gameport Joystick

00:09.0 USB controller: VIA Technologies, Inc. VT82xx/62xx UHCI USB 1.1 Controller (rev 61)

        Subsystem: VIA Technologies, Inc. VT82xx/62xx UHCI USB 1.1 Controller

        Kernel driver in use: uhci_hcd

00:09.1 USB controller: VIA Technologies, Inc. VT82xx/62xx UHCI USB 1.1 Controller (rev 61)

        Subsystem: VIA Technologies, Inc. VT82xx/62xx UHCI USB 1.1 Controller

        Kernel driver in use: uhci_hcd

00:09.2 USB controller: VIA Technologies, Inc. USB 2.0 (rev 63)

        Subsystem: VIA Technologies, Inc. USB 2.0 Controller

        Kernel driver in use: ehci-pci

00:11.0 ISA bridge: VIA Technologies, Inc. VT8233 PCI to ISA Bridge

        Subsystem: VIA Technologies, Inc. VT8233 PCI to ISA Bridge

00:11.1 IDE interface: VIA Technologies, Inc. VT82C586A/B/VT82C686/A/B/VT823x/A/C PIPC Bus Master IDE (rev 06)

        Subsystem: VIA Technologies, Inc. VT82C586/B/VT82C686/A/B/VT8233/A/C/VT8235 PIPC Bus Master IDE

        Kernel driver in use: pata_via

00:11.2 USB controller: VIA Technologies, Inc. VT82xx/62xx UHCI USB 1.1 Controller (rev 1b)

        Subsystem: VIA Technologies, Inc. (Wrong ID) onboard UHCI USB 1.1 Controller

        Kernel driver in use: uhci_hcd

00:11.3 USB controller: VIA Technologies, Inc. VT82xx/62xx UHCI USB 1.1 Controller (rev 1b)

        Subsystem: VIA Technologies, Inc. (Wrong ID) onboard UHCI USB 1.1 Controller

        Kernel driver in use: uhci_hcd

00:11.4 USB controller: VIA Technologies, Inc. VT82xx/62xx UHCI USB 1.1 Controller (rev 1b)

        Subsystem: VIA Technologies, Inc. (Wrong ID) onboard UHCI USB 1.1 Controller

        Kernel driver in use: uhci_hcd

01:00.0 VGA compatible controller: NVIDIA Corporation NV11 [GeForce2 MX/MX 400] (rev b2)
```

----------

## NeddySeagoon

Bobr, 

Please tell how you build and install your kernel.

From inside the chroot, the output of 

```
ls -l /boot
```

will be informative too.

----------

## NeddySeagoon

TigerJr,

From Bobrs kernel

```
CONFIG_HAVE_IDE=y

# CONFIG_IDE is not set
```

so the Depreciated IDE drivers menu is off.

All of the PATA drivers moved to SATA menu and got SCSI device names around kernel 2.6.26.

Soon after, udev stopped making the /dev IDE node names, so it gets very messy if you use the IDE drivers.

```
# CONFIG_SATA_VIA is not set

# CONFIG_PATA_VIA is not set
```

are for different VIA chip sets.  The kernel help explains it.

----------

## Bobr

I basically followed the handbook (https://wiki.gentoo.org/wiki/Handbook:X86/Installation/Kernel).

First I downloaded kernel by: 

```
emerge --ask sys-kernel/gentoo-sources
```

In previous installation I tried using genkernel, but compilation was never succesful. So I downloaded pciutils and tried to do it manually.

I have to disable "64bit kernel" option. (Compilation did not work with it.) Then I chose ext2 and ext3 filesystems, processor family changed to athlon and left everything else as it was. (It seemed to be OK to me.) I finished with 

```
make && make modules_install

make install
```

ls -l /boot (from inside chroot):

```
celkem 18049

-rw-r--r-- 1 root root     512 22.■led 11.38 boot.0800

-rw-r--r-- 1 root root  100352 25.■led 07.16 config-4.1.12-gentoo

-rw-r--r-- 1 root root   98474 22.■led 11.02 config-4.1.12-gentoo.old

-rw-r--r-- 1 root root 1348852 21.■led 13.41 initramfs-genkernel-x86-4.1.12-gentoo

drwx------ 2 root root   12288 21.■led 09.25 lost+found

-rw------- 1 root root  130560 25.■led 13.53 map

-rw-r--r-- 1 root root 2546489 25.■led 07.16 System.map-4.1.12-gentoo

-rw-r--r-- 1 root root 2526081 22.■led 11.02 System.map-4.1.12-gentoo.old

-rw-r--r-- 1 root root 5837632 25.■led 07.16 vmlinuz-4.1.12-gentoo

-rw-r--r-- 1 root root 5795744 22.■led 11.02 vmlinuz-4.1.12-gentoo.old
```

Thanks

Bobr

----------

## NeddySeagoon

Bobr,

I was wanting to read the dates/times on your files in boot.  As its a new install, I guess that 

```
22.■led 11.38
```

 is 11.38 on 22 Jan 2016.

Thu file name

```
 initramfs-genkernel-x86-4.1.12-gentoo
```

is interesting.  It indicates that you have a 32 bit install that started out with a stage3 with i686 in the file name.  Further, your Apollo KT266 motherboard chipset only supports 32 bit CPUs.

Your new kernel is there 

```
25.■led 07.16 vmlinuz-4.1.12-gentoo
```

 that's early today.

Did you run /sbin/lilo after the kernel install?

If that's not the problem, please pastebin the config-4.1.12-gentoo file from your /boot.

----------

## Bobr

Yes, 22 Jan is correct. Stage3 with i686 also. I ran /sbin/lilo (I ran it today again to be sure.)

config-4.1.12-gentoo from /boot is there:

https://bpaste.net/show/30bb01d43691

Thanks

Bobr

----------

## TigerJr

 *Bobr wrote:*   

> Using hda instead of sda, after /sbin/lilo:
> 
> ```
> 
> Warning: LBA32 addressing assumed
> ...

 

you can use in lilo.conf

 *Quote:*   

> disk=/dev/sda

 

to install on sda device with hda root bootloader

 *Bobr wrote:*   

> 
> 
> lspci -k:
> 
> ```
> ...

 

So kernel driver is in use: CONFIG_PATA_VIA used scsi subsystem to mount device as /dev/sda, but another driver those you compiled in kernel makes node as /dev/hda those takes control of IDE interface devices...  

Maybe you can try to remove that driver:

CONFIG_BLK_DEV_VIA82CXXX=y

----------

## Bobr

Thanks!!!

Removing CONFIG_BLK_DEV_VIA82CXXX helped. I finished the installation.

NeddySeagoon and TigerJr, I thank you very much for your continuous help. I wish I can understand computers and linux more. I hope using Gentoo would help me to learn more.

All the best

Bobr

----------

## NeddySeagoon

Bobr,

The entire < > ATA/ATAPI/MFM/RLL support (DEPRECATED)  ---- menu should be off.

Here's the history.  The original PC hard drives, by Sugart used an analogue PCB on the hard drive itself and a digital card plugged into an 8 bit or 16 bit ISA slot.

We are talking about the original IBM PC and 286 and clones here.  Mid to late 80's.

Compaq introduced a machine with a hard drive that had Integrated Drive Electronics, together with the well known 40 pin connector.. At first, it connected to a digital card that also provided, all the other interfaces too. However, the 40 pin IDE connector provides nothing more than a cut down 16 bit ISA slot.

With this new interface, compaq needed some new drivers.  They took the SCSI standard of the day and simplified it. Thus IDE/PATA is cot down SCSI in more ways than one.  SCSI was well established before the IBM PC was first though of.

The kernel has always carried PATA and SCSI drivers separately.  IDE turned into a mess as different hard drive vendors implemented different features to improve the performance of their products. CDROMs were also grafted on with the ATA Packet Interface (ATAPI). 

When SATA came along, it used SCSI protcols the from the outset.

Now me have real SCSI, cut down SCSI (IDE) and SATA, all doing similar things.  The kernel devs took the decision to move the IDE/PATA drivers under the SATA high level code. This completed some time ago and the old ATA/ATAPI/MFM/RLL support  has all but been abandoned.  Most notably, you don't get any /dev nodes for the old drivers any more.

This accounts for why IDE devices now have SCSI device names.

SCSI has spread further for block devices too.  USB storage uses the SCSI protocol over USB, there is even SCSI over firewire, over ethernet.

So much for the history.

When you compile both drivers - neither work as they fight over the hardware.

----------

## Bobr

Thanks for explaining. I see the problem now.

----------

