Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 56892

Summary: udev wrongly registered hda partitions as hdc partitions
Product: Gentoo Linux Reporter: Chin Yee <polar88bear>
Component: [OLD] Core systemAssignee: Greg Kroah-Hartman (RETIRED) <gregkh>
Severity: normal    
Priority: High    
Version: 1.4   
Hardware: x86   
OS: Linux   
Package list:
Runtime testing required: ---

Description Chin Yee 2004-07-13 06:19:45 UTC
I am using 
gentoo-dev-sources-2.6.7-r9 and 
udev 030. 

I have a 40GB ATA hdd installed as Primary Master IDE device and a CD-RW drive installed as Secondary Master IDE device and my fstab is listed below, 


 # <fs>          <mountpoint>     <type>         <opts>            <dump/pass> 
 # NOTE: If your BOOT partition is ReiserFS, add the notail option to opts. 
 /dev/hda1      /boot           ext2            noauto,noatime,nodev    1 1 
 /dev/hda5       /               reiserfs        noatime                 0 0 
 /dev/hda6       /tmp            ext2            noatime,nodev,noexec    0 2 
 /dev/hda7       /var            reiserfs        noatime,nodev           0 0 
 /dev/hda8       none            swap            sw                      0 0 
 /dev/hda9       /usr            reiserfs        noatime,nodev           0 0 
 /dev/hda10      /usr/portage    reiserfs        noatime,nodev           0 0 
 /dev/hda11      /home           reiserfs        noatime,nodev,noexec    0 0 
 /dev/cdrom      /mnt/cdrom      iso9660         noauto,ro               0 0 
 /dev/fd0        /mnt/floppy     vfat            noauto                  0 0 
I have /dev file system and auto mount devfs compiled into my kernel. My system boot up correctly without problem. However, When I try booting up my system with kernel options,
 devfs=nomount gentoo=nodevfs 
as suggested in the udev guide, although I can get a login in prompt, /dev/hda8 and beyond are not mounted. I had a look at my /dev directory, I only have /dev/hda1 -> /dev/hda7 listed. And strangely, though I only have a cdrom drive (no CDROM inserted) installed as a secondary master IDE device, /dev/hdc1 -> /dev/hdc11 appeared in my /dev directory. obviously my hda partitions are wrongly registered as hdc partitions. And I cannot mount any of the hdc[x] partitions.
Comment 1 Greg Kroah-Hartman (RETIRED) gentoo-dev 2004-07-13 10:02:58 UTC
When running devfs, does the block devices in /sys/block point to the proper 
disks (hda being your hard disk, and hdc being your cdrom)?

Does this layout of /sys/block then change without devfs?
Comment 2 Chin Yee 2004-07-13 19:39:50 UTC
In both instances (with devfs and without devfs) /sys/block showed the proper partitions.  


bash-2.05b$ pwd
bash-2.05b$ ls
dev  device  queue  range  size  stat

bash-2.05b$ pwd
bash-2.05b$ ls
dev     hda1   hda11  hda6  hda8  queue  size
device  hda10  hda5   hda7  hda9  range  stat

The difference is in /dev.
Comment 3 Greg Kroah-Hartman (RETIRED) gentoo-dev 2004-09-20 16:01:11 UTC
Please try udev-032
Comment 4 Chin Yee 2004-09-20 18:29:52 UTC
I've found the solution to the problem. The problem seem to lie in the existenece of the file /dev/.devfsd. /sbin/rc tries to delete this file when the system boots up before and root partition is mounted rw and therefore failed. So I booted the system with a live CD and deleted /dev/.devfsd and the problem is gone. Perhaps this is to be added to the Gentoo udev guide.
Comment 5 Greg Kroah-Hartman (RETIRED) gentoo-dev 2004-09-20 19:39:38 UTC
Great, I'll mark this close.

I don't know who wrote that document :(
Comment 6 Chin Yee 2004-09-20 20:18:43 UTC
Perhaps the bug in /sbin/rc should be reported to the baselayout maintainer.