You are not logged in.

#1 2010-08-22 18:47:28

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,595
Website

Unable to determine major/minor number root device /dev/sda [SOLVED]

I'm installing Arch i686 on a rather old PC. Athlon 3000+ on an Asus A7N8X-E motherboard with 512 meg of RAM, blah blah.  I have successfully installed Arch on similar machines of this vintage just fine.

I partitioned it as follows:

/dev/sda1 /boot
/dev/sda2 /
/dev/sda3 swap
/dev/sda4 /home

It gets to grub just fine, but hangs up with an error message I haven't seen before:


:: Loading Initramfs
:: Starting udevd...
done.
Waiting 10 seconds for device /dev/sda2 ...
ERROR: Unable to determine major/minor number of root device '/dev/sda2'.

Then I get dropped to a recovery shell.  I search and found a similar threads where the solution has been to regenerate the initramfs images which I have tried several times over.  Same problem.  Love to understand what I'm doing incorrectly here!

Relevant line in /boot/grub/menu.lst

# (0) Arch Linux
title  Arch Linux
root   (hd0,0)
kernel /vmlinuz26 root=/dev/sda2 ro quiet
initrd /kernel26.img

/etc/fstab

devpts                 /dev/pts      devpts    defaults            0      0
shm                    /dev/shm      tmpfs     nodev,nosuid        0      0

#/dev/cdrom             /media/cd   auto    ro,user,noauto,unhide   0      0
#/dev/dvd               /media/dvd  auto    ro,user,noauto,unhide   0      0
#/dev/fd0               /media/fl   auto    user,noauto             0      0

/dev/sda1 /boot ext3 defaults 0 1
/dev/sda2 / ext4 defaults 0 1
/dev/sda3 swap swap defaults 0 0
/dev/sda4 /home ext4 defaults 0 1

/etc/mkinitcpio.conf

MODULES=""
BINARIES=""
FILES=""
HOOKS="autodetect udev base scsi sata pata filesystems"

Last edited by graysky (2010-08-26 22:00:43)


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#2 2010-08-22 18:52:52

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

Can you boot fallback image?

Offline

#3 2010-08-22 18:53:26

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,595
Website

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

@karol - nope, neither the main kernel image nor fallback image work since they were built at the same time by the installer scripts.

Last edited by graysky (2010-08-23 08:44:42)


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#4 2010-08-22 18:55:53

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

https://bbs.archlinux.org/viewtopic.php … 22#p767322
remove autodetect from HOOKS in /etc/mkinitcpio.conf and rebuild the image

Edit: I think it will mean you boot into an image quite like the fallback one, so maybe it wasn't the smartest idea.

Last edited by karol (2010-08-22 19:04:47)

Offline

#5 2010-08-22 19:14:25

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,595
Website

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

Removed autodetect as per that post and your suggestion and rebuilt in a chroot.

HOOKS="udev base scsi sata pata filesystems"

Same problem upon the reboot sad

:: Loading Initramfs
:: Starting udevd...
done.
Waiting 10 seconds for device /dev/sda2 ...
ERROR: Unable to determine major/minor number of root device '/dev/sda2'.

What gets me is that the netboot CD is able to boot!

Last edited by graysky (2010-08-22 21:39:56)


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#6 2010-08-22 22:04:51

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,595
Website

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

I booted into the Arch CD again, then did:

# lsmod
Module                  Size  Used by
nls_cp437               4513  1 
vfat                    8210  1 
fat                    42177  1 vfat
usb_storage            33940  1 
snd_wavefront          28397  0 
snd_seq_dummy           1067  0 
snd_cs4236             22188  0 
snd_seq_oss            24984  0 
snd_seq_midi_event      4484  1 snd_seq_oss
snd_seq                41656  5 snd_seq_dummy,snd_seq_oss,snd_seq_midi_event
snd_wss_lib            18624  2 snd_wavefront,snd_cs4236
snd_intel8x0           22200  0 
snd_opl3_lib            7190  2 snd_wavefront,snd_cs4236
snd_hwdep               4752  2 snd_wavefront,snd_opl3_lib
snd_ac97_codec         87943  1 snd_intel8x0
snd_pcm_oss            33442  0 
ac97_bus                 750  1 snd_ac97_codec
snd_mixer_oss          14356  1 snd_pcm_oss
snd_mpu401              3800  0 
snd_mpu401_uart         4915  3 snd_wavefront,snd_cs4236,snd_mpu401
rtc_cmos                7546  0 
snd_pcm                57767  5 snd_cs4236,snd_wss_lib,snd_intel8x0,snd_ac97_codec,snd_pcm_oss
snd_rawmidi            15247  2 snd_wavefront,snd_mpu401_uart
rtc_core               11851  1 rtc_cmos
snd_seq_device          4349  5 snd_seq_dummy,snd_seq_oss,snd_seq,snd_opl3_lib,snd_rawmidi
snd_timer              15629  4 snd_seq,snd_wss_lib,snd_opl3_lib,snd_pcm
snd                    42562  17 snd_wavefront,snd_cs4236,snd_seq_oss,snd_seq,snd_wss_lib,snd_intel8x0,snd_opl3_lib,snd_hwdep,snd_ac97_codec,snd_pcm_oss,snd_mixer_oss,snd_mpu401,snd_mpu401_uart,snd_pcm,snd_rawmidi,snd_seq_device,snd_timer
i2c_nforce2             4780  0 
shpchp                 26528  0 
rtc_lib                 1482  1 rtc_core
nvidia_agp              4132  1 
snd_page_alloc          5873  3 snd_wss_lib,snd_intel8x0,snd_pcm
ppdev                   4850  0 
i2c_core               14855  1 i2c_nforce2
soundcore               5017  1 snd
pci_hotplug            23303  1 shpchp
processor              25806  0 
thermal                 9614  0 
button                  3702  0 
parport_pc             27735  1 
ns558                   1963  0 
agpgart                23119  1 nvidia_agp
lp                      6652  0 
evdev                   6716  0 
parport                25371  3 ppdev,parport_pc,lp
pcspkr                  1347  0 
analog                  7811  0 
gameport                7065  3 ns558,analog
squashfs               19531  2 
loop                   12110  4 
aufs                  143158  1 
exportfs                2906  1 aufs
udf                    79074  1 
sg                     20820  0 
usbhid                 32582  0 
hid                    59859  1 usbhid
sr_mod                 13097  1 
cdrom                  31305  1 sr_mod
sd_mod                 25215  2 
ata_generic             2171  0 
pata_acpi               2296  0 
ohci_hcd               19405  0 
pata_amd                7768  1 
sata_sil                6268  0 
floppy                 47264  0 
libata                138071  4 ata_generic,pata_acpi,pata_amd,sata_sil
skge                   33580  0 
firewire_ohci          20072  0 
scsi_mod               79436  5 usb_storage,sg,sr_mod,sd_mod,libata
ehci_hcd               31420  0 
usbcore               119796  5 usb_storage,usbhid,ohci_hcd,ehci_hcd
firewire_core          38297  1 firewire_ohci
crc_itu_t               1041  2 udf,firewire_core
forcedeth              47287  0 

I try adding a few of these to the MODULES section of mkinitcpio.conf... particularly the driver that the Silicon Image SATA controller is using...

MODULES="sata_sil ata_generic libata pata_amd" and HOOKS="base udev autodetect pata scsi sata filesystems"
The result was the same damn error!

Last edited by graysky (2010-08-22 22:16:46)


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#7 2010-08-23 21:47:32

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,595
Website

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

Man, ubuntu 9 installed and boots just fine on the same machine but it's using grub2.  Perhaps I have to take the grub2 plunge.

Last edited by graysky (2010-08-23 21:52:39)


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#8 2010-08-23 21:51:28

.:B:.
Forum Fellow
Registered: 2006-11-26
Posts: 5,819
Website

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

/dev should be populated dynamically if I'm correct, so it's a bit bizarre to see minor/major number errors like that (I've never seen it about HDs/partitions). You should check the properties of the /dev/sd* entries.

This is how it looks here:

[stijn@hermes ~]$ ll /dev/sd*
brw-rw---- 1 root disk 8, 0 aug 23 19:24 /dev/sda
brw-rw---- 1 root disk 8, 1 aug 23 19:24 /dev/sda1
brw-rw---- 1 root disk 8, 2 aug 23 19:24 /dev/sda2
brw-rw---- 1 root disk 8, 5 aug 23 19:24 /dev/sda5
brw-rw---- 1 root disk 8, 6 aug 23 19:24 /dev/sda6
brw-rw---- 1 root disk 8, 7 aug 23 19:24 /dev/sda7

You can reassign the major/minor numbers yourself afaik.


Got Leenucks? :: Arch: Power in simplicity :: Get Counted! Registered Linux User #392717 :: Blog thingy

Offline

#9 2010-08-24 00:07:25

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,595
Website

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

They are as your's are... 8/1, 8/2, 8/3, etc... I even tried replacing the "root=/dev/sda2" line with "root=0802" but that didn't work.  I tried using grub2 and that didn't work.  I can't explain why Ubuntu can boot but Arch cannot.


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#10 2010-08-24 00:21:31

hokasch
Member
Registered: 2007-09-23
Posts: 1,461

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

How does ubuntu's working menu.lst entry look like?

Offline

#11 2010-08-24 08:34:14

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,595
Website

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

@hokasch - it's using grub2 so there's a grub.cfg which I have overwritten.  I need to reinstall Ubuntu to get at it.


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#12 2010-08-24 23:59:52

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,595
Website

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

Bah, the ubuntu menu.lst looks like my arch menu.lst.  I don't think it's a grub or grub2 issue, I think it's got something to do with Arch's mkinitcpio.  Other ideas are welcomed.


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#13 2010-08-25 01:13:17

my0pic
Member
From: Melbourne, Australia
Registered: 2008-05-23
Posts: 206

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

Frustrating isn't it?
Not sure if this will help but try adding "rootfstype=ext4" (and maybe use root=/dev/disk/by-uuid rather than /dev/sda2) to the kernel line in grub.
Maybe a different kernel such as kernel26-lts will help.
Last resort, I'd wipe/reformat and have  /boot and / on the same partition.

Offline

#14 2010-08-25 06:14:23

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,595
Website

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

I tried adding the rootfstype switch but with the same result and as well using uuids.  I guess it's possible that the mapping gets screwed up from the live cd to the 'native' state.  I need to get dropped to a recovery shell somehow and do a 'ls -l /dev/sd*' to see what the major/minor numbers are from the grub screen somehow.

Check out this very old kerneltrap post by asavva:

asavva wrote:

I had this same problem running on two different machines. I am not sure what causes it but the fix I used was to specify the major and minor numbers of the device that holds the root filesystem.

Eg. If "/" is on /dev/hda2 then type "ls -l /dev/hda2" and you will see the major and minor number of the disk, for example on my system I get:


brw-rw---- 1 root disk 3, 2 Sep 15 14:40 /dev/hda2

Therefore the (major, minor) number are (3,2).

Translate this number to hexadecimal and pad to a two digit number, eg: 3,2 becomes 0302 and you have the hexadecimal form of the block device.

Now you can use this in place of "root=/dev/hda2" or "root=LABEL=/" in /etc/grub.conf

Thus you would use "root=0302" in my case. This should also work with lilo but I have not tested this.

Next question: how can I get to a recovery shell from the grub boot screen to try the 'ls -l /dev/sd*' query?  Hitting 'c' doesn't give me the option to use ls at all.

Last edited by graysky (2010-08-25 06:15:56)


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#15 2010-08-25 07:39:36

my0pic
Member
From: Melbourne, Australia
Registered: 2008-05-23
Posts: 206

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

graysky wrote:

Check out this very old kerneltrap post by asavva:

I saw that earlier but  you had already tried specifying "root=0802".
I was thinking maybe give quick-init from aur a try. I use it on my netbook to speed up boot. Part of the configuration is to specify the hard disk nodes in /etc/qinit.sysinit so they're not created dynamically. I had to put the following for mine:

/bin/mknod -m 660 /dev/sda1 b 8 1
/bin/mknod -m 660 /dev/sda2 b 8 2
/bin/mknod -m 660 /dev/sda3 b 8 3
/bin/mknod -m 660 /dev/sda4 b 8 4

If that works you get a faster boot as a bonus smile

graysky wrote:

Next question: how can I get to a recovery shell from the grub boot screen to try the 'ls -l /dev/sd*' query?  Hitting 'c' doesn't give me the option to use ls at all.

At grub the device nodes aren't created yet. You would only have console, null and zero in /dev.

Oh, forum topic for quick-init: https://bbs.archlinux.org/viewtopic.php?id=72156
And how about adding ext4 to the modules array in mkinitcpio.conf, would that help?

Last edited by my0pic (2010-08-25 07:50:03)

Offline

#16 2010-08-25 20:22:03

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,595
Website

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

Thanks for the idea but the quick-init package assigning the hard disk nodes didn't help sad  This is utterly maddening!


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#17 2010-08-25 21:33:09

mrbrich
Member
Registered: 2010-04-24
Posts: 42

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

Hi.  I'm having the same (or a very similar) problem.  I haven't used my laptop for a while because it was being repaired.  I just got it back today, and when I tried to boot it gave me

Waiting 10 seconds for device /dev/disk/by-uuid/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
Root device '/dev/disk/by-uuid/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx' doesn't exist. Attempting to create it.
ERROR: Unable to determine major/minor number of root device '/dev/disk/by-uuid/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'.

This isn't a new installation, it was working before, but I may have done a system upgrade recently.  I hope you solve your problem and mine at the same time.

Offline

#18 2010-08-25 21:57:21

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,595
Website

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

Perhaps one of us should open a bug report; this seems to be related to mkinitcpio in my naive option.


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#19 2010-08-25 22:57:12

combuster
Member
From: Serbia
Registered: 2008-09-30
Posts: 711
Website

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

This could be a bug with mkinitcpio. I had the same problem but under following circumstances:

When I've tried to build 2.6.35 kernel with config from scratch it gave me the same error over and over again. Doing make oldconfig with .config from 2.6.34 and it worked. I really don't know why and how this could be related, since you probably use Arch stock kernel. And I'm not the only one, couple of my friends had the same error on Arch and all of them resolved it the same way I did.

Offline

#20 2010-08-25 23:16:53

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,595
Website

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

Hmm... yeah, I'm trying to use the stock kernel - no way do I want to compile a custom one for this box.


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#21 2010-08-26 00:08:50

combuster
Member
From: Serbia
Registered: 2008-09-30
Posts: 711
Website

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

Could you try with lts kernel ?

Offline

#22 2010-08-26 01:11:39

mrbrich
Member
Registered: 2010-04-24
Posts: 42

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

I've used both stock kernel and a custom compiled kernel on my machine.  I use the custom kernel because it seems to have lower power consumption (does this make any sense?).  I also tried to add TuxOnIce support to my custom kernel, but never got it to work.  My question is, now that my machine won't boot, how can I fix my problem (if indeed it is related to the custom kernel as suggested)?  Do I have to boot the Arch installation CD and then use chroot?  I think there are some instructions on how to do that in the wiki.

Offline

#23 2010-08-26 04:42:50

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,595
Website

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

@mrbrich - Yes, try this to rebuild your kernel: wiki,  Let's keep this thread on topic though to keep the signal-to-noise up. 

Topic:

ERROR: Unable to determine major/minor number of root device '/dev/sdaX'.

CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#24 2010-08-26 05:00:43

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,595
Website

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

graysky wrote:

Perhaps one of us should open a bug report; this seems to be related to mkinitcpio in my naive option.

http://bugs.archlinux.org/task/20614

Last edited by graysky (2010-08-26 05:09:14)


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#25 2010-08-26 10:38:34

recoctro
Member
Registered: 2010-08-26
Posts: 1

Re: Unable to determine major/minor number root device /dev/sda [SOLVED]

Same problem here, fixed defining the filesystems by labels in fstab.

Offline

Board footer

Powered by FluxBB