Find the answer to your Linux question:
Page 1 of 2 1 2 LastLast
Results 1 to 10 of 13
Hi, good evening everyone. This is my first post, and I really could use some help... I installed Gentoo on a toshiba laptop and it worked fine. Everything is in ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Dec 2005
    Location
    Buenos Aires, Argentina
    Posts
    11

    Installation - boot error: kernel panic


    Hi, good evening everyone. This is my first post, and I really could use some help... I installed Gentoo on a toshiba laptop and it worked fine. Everything is in place and I love it. The issue is when I tried to install gentoo at work. The computers here use SATA hard drives. I followed the 2005.1 installation handbook step by step. However, after rebooting the kernel gives me a kernel panic error: unable to mount root filesystem... before that, it says that /dev/sda3 is not a valid device...first, I tried the manual kernel configuration since it was not my first time compiling the kernel. Then I tried genkernel, and still no luck. The partition layout is the same as in the handbook:

    Code:
    /dev/sda1     32M     ext2     boot
    /dev/sda2    512M    swap    swap
    /dev/sda3    3,5GB   ext3     root
    I tried switching from grub to lilo, and get to the same point. What puzzles me is, that the boot loader is able to "see" the /dev/sda1 partition and loads the kernel, however when the kernel tries to mount the root fs on the other partition it cannot. No matter if it is ext2. no matter if I change lilo.conf or menu.lst to point to /dev/sda1 to mount the root, even if there is no enough space it gives me the exact same error. The kernel is 2.6.12 r6...

    I looked around googling and found that some other people are having this issue, however no solution works for this case. I know that there are no bad blocks on the hard drive...

    Thanks in advance for any assistance.

    EDIT: just in case, Ubuntu Linux installed fine on the same hd.

    MOD_EDIT: Added code tags (also adding them further down). - l_n

  2. #2
    Linux Engineer
    Join Date
    Mar 2005
    Posts
    1,431
    Did you remember to include SATA support in the kernel? Can you possiby post your /boot/grub/menu.lst too?

  3. #3
    Just Joined!
    Join Date
    Dec 2005
    Location
    Buenos Aires, Argentina
    Posts
    11
    Yes, in the first kernel made by hand I added both SATA and SCSI support for the chipset in my motherboard (ASRock p4vm. In the second kernel, created automatically by several scripts by gentoo (the genkernel feature) that one was supposed to have support for all hardware (and it took quite some time to compile, much more than the custom)

    the menu.lst is as follows:
    Code:
    default 0
    timeout 30
    splashimage=(hd0,0)/boot/grub/splash.xpm.gz
    
    root(hd0,0)
    kernel /boot/kernel-2.6.12-gentoo-r6 root=/dev/sda3
    (I also tried loading the kernel with read only command "ro")


    When I attempted lilo, this is the file /etc/lilo.conf:
    Code:
    boot=/dev/sda
    prompt
    timeout=50
    default=gentoo
    
    image=/boot/kernel-2.6.12-gentoo-r6
      label=gentoo
      read-only
      root=/dev/sda3
    It doesn't seen to matter what value I provide for root=... nothing works. I checked the fstab just in case, and everything seems to be correct (I recall once I typed e2xt as a filesystem) also the device.map file shows the sda as the hd0 for grub.

    Thank you for your time!

    Regards.

  4. #4
    Linux Guru budman7's Avatar
    Join Date
    Oct 2004
    Location
    Knee deep in Grand Rapids, Michigan
    Posts
    3,242
    Coud you post the contents of your fstab file? As I suspect that is where the error is.
    How to know if you are a geek.
    when you respond to "get a life!" with "what's the URL?"
    - Birger

    New users read The FAQ

  5. #5
    Just Joined!
    Join Date
    Dec 2005
    Location
    Buenos Aires, Argentina
    Posts
    11
    Sure, here it is (omitting all the comments)

    Code:
    /dev/sda1                    /boot             ext2      defaults,noatime      1 2
    /dev/sda2                    none             swap      sw                          0 0
    /dev/sda3                    /                   ext3       noatime                  0 1
    /dev/cdroms/cdrom0    /mnt/cdrom    iso9660  noauto                    0 0
    /dev/fd0                      /mnt/floppy    auto       noauto                    0 0
    
    none                           /proc              proc    defaults                       0 0
    shm                           /dev/shm         tmpfs   nodev,nosuid,noexec   0 0
    I've tried different options for the device /dev/sda3 as well...

    Thank you!

    kind regards.

  6. #6
    Linux Engineer
    Join Date
    Mar 2005
    Posts
    1,431
    Hmm, I think I know what budman7 thought of (not changing the fstab from the gentoo manual's example), but another thing I reacted to was that in the line "root(hd0,0)" there should be space between "root" and "(hd0,0)"

  7. #7
    Just Joined!
    Join Date
    Dec 2005
    Location
    Buenos Aires, Argentina
    Posts
    11
    I don't recall right now exactly if there is a space between root and (hd0,0)... however, grub still locates the partition and loads the kernel and lilo also, loads the kernel but then the kernel cannot mount the VFS on the partition saying that is not a valid block device

  8. #8
    Linux Guru budman7's Avatar
    Join Date
    Oct 2004
    Location
    Knee deep in Grand Rapids, Michigan
    Posts
    3,242
    Jaboua, that is exactly what I was thinking.
    But, I also have found that a bunch of kernel panics can be solved by correcting the fstab file.

    But, I don't see any problems with your fstab file.
    The only other place that I can think of right now would be your grub.conf file.
    It should be in /grub or /boot/grub
    How to know if you are a geek.
    when you respond to "get a life!" with "what's the URL?"
    - Birger

    New users read The FAQ

  9. #9
    Just Joined!
    Join Date
    Dec 2005
    Location
    Buenos Aires, Argentina
    Posts
    11
    perhaps I am missing something here... don't mean to sound stupid, but the grub.conf file is a softlink to the menu.lst...shouldn't it be that way?

  10. #10
    Linux Guru budman7's Avatar
    Join Date
    Oct 2004
    Location
    Knee deep in Grand Rapids, Michigan
    Posts
    3,242
    grub.conf or menu.lst point to the same file. Or is grub.conf points to menu.lst or menu.lst points to grub.conf?

    It doesn't really matter.
    I just wanted to see what was in there.
    How to know if you are a geek.
    when you respond to "get a life!" with "what's the URL?"
    - Birger

    New users read The FAQ

Page 1 of 2 1 2 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •