View previous topic :: View next topic |
Author |
Message |
queen Veteran
Joined: 19 Jul 2005 Posts: 1642
|
Posted: Mon Jan 28, 2013 10:40 am Post subject: {SOLVED} Block device /dev/sda3 is not a valid root device |
|
|
Hello Everyone
I had a working system on a new laptop for few months already. Suddenly, I had a crash, got a black screen with lots of errors (which I am not sure I can reproduce). The problem is with the boot. When it starts grub it takes more time than usual (instead of a second it takes 6-7 seconds until the splash appears). After that, it starts to boot and fails with
Code: |
!! Block device /dev/sda3 is not a valid root device...
!! Could not find the root block device in .
Please specify another value or: press Enter for the same, type "shell" for shell, or "q" to skip...
root block device() :: |
I don't know what caused it. I did some updates, but didn't update yet udev to 191.
Currently, I am stuck with the message that it doesn't recognize root device.
Any help will be appreciated.
Last edited by queen on Sat Feb 09, 2013 11:26 pm; edited 1 time in total |
|
Back to top |
|
|
tomk Bodhisattva
Joined: 23 Sep 2003 Posts: 7221 Location: Sat in front of my computer
|
Posted: Mon Jan 28, 2013 11:45 am Post subject: |
|
|
Moved from Installing Gentoo to Portage & Programming, if you have posted to the wrong forum you should report it instead of creating a new topic and one of us will move it. _________________ Search | Read | Answer | Report | Strip |
|
Back to top |
|
|
Section_8 l33t
Joined: 22 May 2004 Posts: 627
|
Posted: Mon Jan 28, 2013 4:35 pm Post subject: |
|
|
Just googling that error message, it looks like it's usually happening because something needed is missing from the kernel - either support for the block device, or support for the file system. Did you rebuild your kernel? |
|
Back to top |
|
|
queen Veteran
Joined: 19 Jul 2005 Posts: 1642
|
Posted: Mon Jan 28, 2013 5:25 pm Post subject: |
|
|
Section_8 wrote: | Just googling that error message, it looks like it's usually happening because something needed is missing from the kernel - either support for the block device, or support for the file system. Did you rebuild your kernel? |
I rebuild the kernel few days ago. It was something regarding usbfs and card reader that is on usb port. I didn't touch anything regarding other filesystem which root belongs. root is ext4.
I am trying now to rebuild the kernel by removing usbfs and the card reader.
I also checked the filesystem and it's clean without any errors.
This is the fstab file
Code: | /dev/sda1 /boot ext3 defaults,noatime 1 2
/dev/sda2 none swap sw 0 0
/dev/sda3 / ext4 defaults,noatime 0 2
/dev/cdrom /mnt/cdrom auto noauto,ro 0 0
none /dev/bus/usb usbfs devgid=1014,devmode=664 0 0
proc /proc proc defaults 0 0
shm /dev/shm tmpfs nodev,nosuid,noexec 0 0
none /dev/usb/ usbfs auto,devmode=0666 0 0
|
|
|
Back to top |
|
|
Section_8 l33t
Joined: 22 May 2004 Posts: 627
|
Posted: Tue Jan 29, 2013 3:32 am Post subject: |
|
|
Are you certain that ext4 support is compiled into the kernel - not as a module? |
|
Back to top |
|
|
queen Veteran
Joined: 19 Jul 2005 Posts: 1642
|
Posted: Tue Jan 29, 2013 8:17 pm Post subject: |
|
|
Section_8 wrote: | Are you certain that ext4 support is compiled into the kernel - not as a module? |
Yes. It was always built in. And worked.
Code: | CONFIG_EXT4_FS=y
# CONFIG_EXT4_FS_XATTR is not set
# CONFIG_EXT4_DEBUG is not set
|
Can it be something with udev? I don't have the latest udev (197). I have right now 171 |
|
Back to top |
|
|
Jaglover Watchman
Joined: 29 May 2005 Posts: 8291 Location: Saint Amant, Acadiana
|
Posted: Tue Jan 29, 2013 9:38 pm Post subject: Re: Block device /dev/sda3 is not a valid root device |
|
|
queen wrote: | Hello Everyone
I had a working system on a new laptop for few months already. Suddenly, I had a crash, got a black screen with lots of errors (which I am not sure I can reproduce). The problem is with the boot. When it starts grub it takes more time than usual (instead of a second it takes 6-7 seconds until the splash appears). After that, it starts to boot and fails with ... |
Sounds like hardware failure to me, or at least filesystem corruption. _________________ My Gentoo installation notes.
Please learn how to denote units correctly! |
|
Back to top |
|
|
queen Veteran
Joined: 19 Jul 2005 Posts: 1642
|
Posted: Thu Jan 31, 2013 7:49 am Post subject: Re: Block device /dev/sda3 is not a valid root device |
|
|
Jaglover wrote: | queen wrote: | Hello Everyone
I had a working system on a new laptop for few months already. Suddenly, I had a crash, got a black screen with lots of errors (which I am not sure I can reproduce). The problem is with the boot. When it starts grub it takes more time than usual (instead of a second it takes 6-7 seconds until the splash appears). After that, it starts to boot and fails with ... |
Sounds like hardware failure to me, or at least filesystem corruption. |
BTW, I upgraded udev and it didn't solve the problem. Right now grub starts fast but fails in mounting root. How can I check if it's a hardware failure? In chroot I can see /dev/sda3 (/) completely. I also ran fsck.ext4 and it says it's clean. |
|
Back to top |
|
|
steveL Watchman
Joined: 13 Sep 2006 Posts: 5153 Location: The Peanut Gallery
|
Posted: Thu Jan 31, 2013 12:52 pm Post subject: Re: Block device /dev/sda3 is not a valid root device |
|
|
queen wrote: | Jaglover wrote: | Sounds like hardware failure to me, or at least filesystem corruption. |
BTW, I upgraded udev and it didn't solve the problem. Right now grub starts fast but fails in mounting root. How can I check if it's a hardware failure? In chroot I can see /dev/sda3 (/) completely. I also ran fsck.ext4 and it says it's clean. |
If you can access it in chroot and not on main system, that does sound like you're missing something built-in: the classic things are the fs, which you've covered, the motherboard drivers (SATA usually, but specific to your hard-drive controller) and scsi-disk which is needed to access modern drives. You might have accidentally done something to one of those while changing kernel config recently.
Another thing that struck me was that you have /boot listed before / in /etc/fstab: as man fstab says:
"The order of records in fstab is important because fsck(8), mount(8), and umount(8) sequentially iterate through fstab doing their thing."
I've always been careful of ordering, so /usr has to be listed before /usr/local or /usr/src, and / before anything apart from swap. Not sure if that's it, of course, but it doesn't hurt to try (I noticed /boot seemed stuck on at the top.) |
|
Back to top |
|
|
padoor Advocate
Joined: 30 Dec 2005 Posts: 4185 Location: india
|
Posted: Thu Jan 31, 2013 3:27 pm Post subject: |
|
|
cfdisk /dev/sda
may show if any partition table corruption has come up.
the delay is it is looking up for the root partition
i have had such troubles in new intallations only.
this makes me worry as i am also running a few months old new laptop gentoo-x32 and gentoo-x64 with windows 7 and 8 in partitions of the same disk.
i am also intersted in a solution to this problem _________________ reach out a little bit more to catch it (DON'T BELIEVE the advocate part under my user name) |
|
Back to top |
|
|
queen Veteran
Joined: 19 Jul 2005 Posts: 1642
|
Posted: Fri Feb 01, 2013 9:47 pm Post subject: Re: Block device /dev/sda3 is not a valid root device |
|
|
steveL wrote: | queen wrote: | Jaglover wrote: | Sounds like hardware failure to me, or at least filesystem corruption. |
BTW, I upgraded udev and it didn't solve the problem. Right now grub starts fast but fails in mounting root. How can I check if it's a hardware failure? In chroot I can see /dev/sda3 (/) completely. I also ran fsck.ext4 and it says it's clean. |
If you can access it in chroot and not on main system, that does sound like you're missing something built-in: the classic things are the fs, which you've covered, the motherboard drivers (SATA usually, but specific to your hard-drive controller) and scsi-disk which is needed to access modern drives. You might have accidentally done something to one of those while changing kernel config recently.
Another thing that struck me was that you have /boot listed before / in /etc/fstab: as man fstab says:
"The order of records in fstab is important because fsck(, mount(, and umount( sequentially iterate through fstab doing their thing."
I've always been careful of ordering, so /usr has to be listed before /usr/local or /usr/src, and / before anything apart from swap. Not sure if that's it, of course, but it doesn't hurt to try (I noticed /boot seemed stuck on at the top.) |
Thanks for the tips. The changes I made in the kernel were about the card reader. ( I doubled checked, AHCI (sata controller) and AHCI PLATFORM appears in the kernel and I didn't touch it.
Regarding fstab, I will change the order, although this was the order for the last 4 months and I never had a problem.
But it's worth to try to re-write fstab.
OPTION 2 I might try to configure a newer kernel like 3.6.
Right now I DIDN'T chroot into the system and just mounted only /dev/sda3 which is root. I looked under / and found only /dev/null. is it normal? Or I was supposed to see more? I didn't run Code: | mount --rbind /dev /mnt/gentoo/dev |
Is there a way to check if there is a problem with the hardware before I give it to the lab? lspci appears to be fine. Memtest showed there are no errors.
Last edited by queen on Fri Feb 01, 2013 9:54 pm; edited 1 time in total |
|
Back to top |
|
|
queen Veteran
Joined: 19 Jul 2005 Posts: 1642
|
Posted: Fri Feb 01, 2013 9:51 pm Post subject: |
|
|
padoor wrote: | cfdisk /dev/sda
may show if any partition table corruption has come up.
the delay is it is looking up for the root partition
i have had such troubles in new intallations only.
this makes me worry as i am also running a few months old new laptop gentoo-x32 and gentoo-x64 with windows 7 and 8 in partitions of the same disk.
i am also intersted in a solution to this problem |
Thanks. I"ll give it a try. |
|
Back to top |
|
|
Chiitoo Administrator
Joined: 28 Feb 2010 Posts: 2575 Location: Here and Away Again
|
Posted: Wed Feb 06, 2013 2:44 pm Post subject: Re: Block device /dev/sda3 is not a valid root device |
|
|
steveL wrote: | Another thing that struck me was that you have /boot listed before / in /etc/fstab: as man fstab says:
"The order of records in fstab is important because fsck(, mount(, and umount( sequentially iterate through fstab doing their thing." |
I took a gander at mine, which has one partition for my own stuff, the /boot, and swap before / and then I checked the Handbook as I didn't think I would venture far from its guidance:
Code Listing 1.3: A full /etc/fstab example Code: | /dev/sda1 /boot ext2 defaults,noatime 0 2
/dev/sda2 none swap sw 0 0
/dev/sda3 / ext3 noatime 0 1
/dev/cdrom /mnt/cdrom auto noauto,user 0 0 |
Only thing regarding the fstab I have done after the first real install over 2 years ago, was that I recently changed /boot to 'noauto'. That doesn't mean that it doesn't matter at all for anything else. The order that is. But I doubt it would get overlooked in this particular case, so the comment in the man page is probably aimed at other stuff. Probably. ^^;
queen,
You probably have it 'covered', but it might be a good idea to pastebin your Kernel .config for a few more looks, just to be sure. Also, you could fire up something like SystemRescueCd or whatever you are using and if you haven't, check dmesg for any errors/faults\nasties.
Running some tests on the hard-drive(s) might not be a bad idea either (I forget the tool I last used myself (probably smartctl), but there exist a lot of info about such all over the place).
Good luck~ _________________ Kindest of regardses. |
|
Back to top |
|
|
queen Veteran
Joined: 19 Jul 2005 Posts: 1642
|
Posted: Sat Feb 09, 2013 9:16 am Post subject: Re: Block device /dev/sda3 is not a valid root device |
|
|
HI Chiitoo
Thanks for the tips. First, few things that I checked. During the boot, it fails before it even starts to read fstab. I did a small experiment. Wrote in fstab sda9 (which doesn't exist), instead of sda3 and it didn't complain. After that I changed in grub.conf real_root=sda9 and there it complained. So, it takes from grub. I also emerged again grub and ran grub install. Same error.
I suspect that /dev files were somehow wiped. If I mount /mnt/gentoo I see there only /dev/null and nothing more. I think there should be more there. If I mount /dev from live dvd to /mnt/gentoo/dev I see much more.
How do I create a normal /dev?
Regarding dmesg, from the live dvd (after mount of /mnt/gentoo ) i didn't see anything special. But I will take a look again.
I will post the kernel config later. HD control I ran fsck.ext4 /dev/sda3 also fsck dev/sda. This is clean. Besides, after I mount /mnt/gentoo I can see everything.
never Heard of smartctl. Will take a look. |
|
Back to top |
|
|
Chiitoo Administrator
Joined: 28 Feb 2010 Posts: 2575 Location: Here and Away Again
|
Posted: Sat Feb 09, 2013 12:32 pm Post subject: Re: Block device /dev/sda3 is not a valid root device |
|
|
queen wrote: | I suspect that /dev files were somehow wiped. If I mount /mnt/gentoo I see there only /dev/null and nothing more. I think there should be more there. If I mount /dev from live dvd to /mnt/gentoo/dev I see much more.
How do I create a normal /dev? |
I didn't say anything about that yet since my knowledge about udev is more than lacking; I never really looked into it, and simply let it do its thing. You also mentioned you didn't update udev. Anyblue, as I understand it, udev should create those device nodes for you, so perhaps your suspicions are not that much off.
If you haven't stumbled upon it before, here's some interesting (I think) read about it (and the wiki article for good measure), and some examples on how to manually create those nodes (might help with testing?): queen wrote: | Regarding dmesg, from the live dvd (after mount of /mnt/gentoo ) i didn't see anything special. But I will take a look again. |
Might be worth to pastebin that as well.
queen wrote: | never Heard of smartctl. Will take a look. |
Apparently I forgot to add that it's a part of sys-apps/smartmontools. _________________ Kindest of regardses. |
|
Back to top |
|
|
padoor Advocate
Joined: 30 Dec 2005 Posts: 4185 Location: india
|
Posted: Sat Feb 09, 2013 4:34 pm Post subject: |
|
|
the /dev will come up even if you delete everything in it.
it is supposed to be regenerating. previous /dev i have deleted and found t still booted correctly in an older installation.
it may not be your current roblem _________________ reach out a little bit more to catch it (DON'T BELIEVE the advocate part under my user name) |
|
Back to top |
|
|
queen Veteran
Joined: 19 Jul 2005 Posts: 1642
|
Posted: Sat Feb 09, 2013 10:18 pm Post subject: |
|
|
padoor wrote: | the /dev will come up even if you delete everything in it.
it is supposed to be regenerating. previous /dev i have deleted and found t still booted correctly in an older installation.
it may not be your current roblem |
Thanks. I think I found the problem and the solution.Cross fingers for me. Someone had a very similar problem like mine. Here is the link
https://forums.gentoo.org/viewtopic-t-949034-highlight-newroot.html
PS. Solved. The problem was in the grub line init=linuxrc. I removed it and it worked. I also followed the udev guide and ran from chroot Code: | mknod -m 660 console c 5 1 | because it disappeared. |
|
Back to top |
|
|
padoor Advocate
Joined: 30 Dec 2005 Posts: 4185 Location: india
|
Posted: Sun Feb 10, 2013 6:22 am Post subject: |
|
|
i am glad it works for you.
i have no init= lie in my grub menu.lst
i use old grub. not grub2
grub2 update has given me much more problems like hdd itself not recognised sometimes back.
anyways you could avoid a reinstall _________________ reach out a little bit more to catch it (DON'T BELIEVE the advocate part under my user name) |
|
Back to top |
|
|
queen Veteran
Joined: 19 Jul 2005 Posts: 1642
|
Posted: Sun Feb 10, 2013 5:40 pm Post subject: |
|
|
padoor wrote: | i am glad it works for you.
i have no init= lie in my grub menu.lst
i use old grub. not grub2
grub2 update has given me much more problems like hdd itself not recognised sometimes back.
anyways you could avoid a reinstall |
Yes, I didn't want to reinstall. Worse, I had a point when I started to think it's a hardware problem. And Jaglover also suggested it's a hardware problem.
I don't think it's grub problem. It's udev problem here. I had another udev problem a year ago. Udev upgrades cause problems. |
|
Back to top |
|
|
|