| View previous topic :: View next topic |
| Author |
Message |
ZeLegolas Tux's lil' helper

Joined: 26 Apr 2005 Posts: 128
|
Posted: Sat Mar 20, 2010 6:03 am Post subject: /dev/hda missing [SOLVED] |
|
|
Hi
I have something very strange
When my computer boot at the boot time it's detect everything, but when I check:
| Code: | # ls -l /dev/h*
ls: cannot access /dev/h*: No such file or directory |
I'm not able to mount my boot partition:
| Code: | # mount /boot
mount: special device /dev/hda1 does not exist |
I have a disk on /dev/hda but I don't see it!
And if I check:
| Code: | # ls -l /sys/block/hda/
total 0
-r--r--r-- 1 root root 4096 Mar 20 01:56 alignment_offset
lrwxrwxrwx 1 root root 0 Mar 20 01:56 bdi -> ../../class/bdi/3:0
-r--r--r-- 1 root root 4096 Mar 20 01:56 capability
-r--r--r-- 1 root root 4096 Mar 20 01:56 dev
lrwxrwxrwx 1 root root 0 Mar 20 01:56 device -> ../../devices/pci0000:00/0000:00:0f.1/ide0/0.0
-r--r--r-- 1 root root 4096 Mar 20 01:56 ext_range
drwxr-xr-x 4 root root 0 Mar 20 01:56 hda1
drwxr-xr-x 4 root root 0 Mar 20 01:56 hda2
drwxr-xr-x 4 root root 0 Mar 20 01:56 hda3
drwxr-xr-x 2 root root 0 Mar 20 01:56 holders
-r--r--r-- 1 root root 4096 Mar 20 01:56 inflight
drwxr-xr-x 2 root root 0 Mar 20 01:56 power
drwxr-xr-x 3 root root 0 Mar 20 01:56 queue
-r--r--r-- 1 root root 4096 Mar 20 01:56 range
-r--r--r-- 1 root root 4096 Mar 20 01:56 removable
-r--r--r-- 1 root root 4096 Mar 20 01:56 ro
-r--r--r-- 1 root root 4096 Mar 20 01:56 size
drwxr-xr-x 2 root root 0 Mar 20 01:56 slaves
-r--r--r-- 1 root root 4096 Mar 20 01:56 stat
lrwxrwxrwx 1 root root 0 Mar 20 01:56 subsystem -> ../../block
-rw-r--r-- 1 root root 4096 Mar 20 01:56 uevent |
The disk exist! For sure Linux is running on it!
When I rebuild udev it's told me to disable CONFIG_IDE but I cannot mount my boot partition how I can rebuild the kernel??? 
Last edited by ZeLegolas on Sun Apr 04, 2010 2:54 pm; edited 1 time in total |
|
| Back to top |
|
 |
cz0 Apprentice

Joined: 13 Jun 2005 Posts: 171 Location: /earth/russia/moscow
|
|
| Back to top |
|
 |
Rexilion l33t


Joined: 17 Mar 2009 Posts: 974
|
Posted: Sat Mar 20, 2010 7:00 am Post subject: |
|
|
Try placing the kernel in a boot directory on your current root partition, make sure that grub.conf points to it. That way you can build a kernel that can access /boot again. However, I think something more is going on. Can you post the output of:
dmesg
please? |
|
| Back to top |
|
 |
aderesch Tux's lil' helper

Joined: 06 Mar 2010 Posts: 110 Location: Berlin, Germany
|
Posted: Sat Mar 20, 2010 7:11 am Post subject: Re: /dev/hda missing |
|
|
| ZeLegolas wrote: | The disk exist! For sure Linux is running on it! :)
When I rebuild udev it's told me to disable CONFIG_IDE but I cannot mount my boot partition how I can rebuild the kernel??? :? |
Sounds like you are only missing the device nodes.
| Code: | | mknod /dev/hda b 3 0; for i in 1 2 3;do mknod /dev/hda${i} b 3 ${i};done |
should take care of that (if your shell is bash).
Then mount and build a kernel using the libata drivers -- before booting that, you should replace references to hd? by sd?, at least in all boot-critical places.
ad |
|
| Back to top |
|
 |
d2_racing Moderator


Joined: 25 Apr 2005 Posts: 12867 Location: Ste-Foy,Canada
|
Posted: Sat Mar 20, 2010 12:59 pm Post subject: |
|
|
What happen when you run this :
_________________ Sysadmin of Funtoo-Québec.org
Wiki
Signature
IRC on Freenode : #funtoo-quebec |
|
| Back to top |
|
 |
ZeLegolas Tux's lil' helper

Joined: 26 Apr 2005 Posts: 128
|
Posted: Sun Mar 21, 2010 2:28 pm Post subject: |
|
|
| d2_racing wrote: | What happen when you run this :
|
I just see my other disk not the hda
| Code: | # fdisk -l
Disk /dev/sda: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x005423cb
Device Boot Start End Blocks Id System
/dev/sda1 1 1245 10000431 83 Linux
/dev/sda2 1246 9729 68147730 83 Linux |
|
|
| Back to top |
|
 |
ZeLegolas Tux's lil' helper

Joined: 26 Apr 2005 Posts: 128
|
Posted: Sun Mar 21, 2010 2:30 pm Post subject: |
|
|
| Rexilion wrote: | | Try placing the kernel in a boot directory on your current root partition, make sure that grub.conf points to it. |
Difficult for that I have to have access to the boot partition! |
|
| Back to top |
|
 |
Rexilion l33t


Joined: 17 Mar 2009 Posts: 974
|
Posted: Sun Mar 21, 2010 2:31 pm Post subject: |
|
|
| ZeLegolas wrote: | | Rexilion wrote: | | Try placing the kernel in a boot directory on your current root partition, make sure that grub.conf points to it. |
Difficult for that I have to have access to the boot partition! |
Okay, and temporarily install grub on it  |
|
| Back to top |
|
 |
ZeLegolas Tux's lil' helper

Joined: 26 Apr 2005 Posts: 128
|
Posted: Sun Mar 21, 2010 2:32 pm Post subject: Re: /dev/hda missing |
|
|
| aderesch wrote: |
Sounds like you are only missing the device nodes.
| Code: | | mknod /dev/hda b 3 0; for i in 1 2 3;do mknod /dev/hda${i} b 3 ${i};done |
should take care of that (if your shell is bash).
Then mount and build a kernel using the libata drivers -- before booting that, you should replace references to hd? by sd?, at least in all boot-critical places.
ad |
I'm using bash
thanks for i will try |
|
| Back to top |
|
 |
ZeLegolas Tux's lil' helper

Joined: 26 Apr 2005 Posts: 128
|
Posted: Sun Mar 21, 2010 2:35 pm Post subject: |
|
|
Thanks for your advice.
For the moment I can not do anything on the server
When it will be possible I will try to create the node manually like aderesch told me and build the kernel without CONFIG_IDE.
I will let you know the result... |
|
| Back to top |
|
 |
ZeLegolas Tux's lil' helper

Joined: 26 Apr 2005 Posts: 128
|
Posted: Sun Apr 04, 2010 8:03 am Post subject: |
|
|
First good news with the command of aderesh I was abled to access to my boot partition (and my other partition too)
The bad new it's If I remove CONFIG_IDE like it's asked udev at the boot time I have this message:
| Quote: | Block device /dev/sda1 is not valid root device
Could not find the root block device in |
For now I put back my old kernel but if someone have any ideas...  |
|
| Back to top |
|
 |
VoidMage Advocate


Joined: 14 Oct 2006 Posts: 4060
|
Posted: Sun Apr 04, 2010 11:50 am Post subject: |
|
|
If you drop CONFIG_IDE (as you probably should),
you need to select correct drivers under CONFIG_ATA. |
|
| Back to top |
|
 |
d2_racing Moderator


Joined: 25 Apr 2005 Posts: 12867 Location: Ste-Foy,Canada
|
Posted: Sun Apr 04, 2010 2:05 pm Post subject: |
|
|
Also your HDD will become /dev/sd* instead of /dev/hd* _________________ Sysadmin of Funtoo-Québec.org
Wiki
Signature
IRC on Freenode : #funtoo-quebec |
|
| Back to top |
|
 |
ZeLegolas Tux's lil' helper

Joined: 26 Apr 2005 Posts: 128
|
Posted: Sun Apr 04, 2010 2:48 pm Post subject: |
|
|
| VoidMage wrote: | If you drop CONFIG_IDE (as you probably should),
you need to select correct drivers under CONFIG_ATA. |
It's what I have done |
|
| Back to top |
|
 |
ZeLegolas Tux's lil' helper

Joined: 26 Apr 2005 Posts: 128
|
Posted: Sun Apr 04, 2010 2:49 pm Post subject: |
|
|
| d2_racing wrote: | | Also your HDD will become /dev/sd* instead of /dev/hd* |
No it just missing |
|
| Back to top |
|
 |
ZeLegolas Tux's lil' helper

Joined: 26 Apr 2005 Posts: 128
|
Posted: Sun Apr 04, 2010 2:53 pm Post subject: |
|
|
Ok it's fine now. I build ATA section (just module that I need) in static mode not like a module.
I just don't understand why the module are not working
Thanks for your support |
|
| Back to top |
|
 |
VoidMage Advocate


Joined: 14 Oct 2006 Posts: 4060
|
Posted: Sun Apr 04, 2010 3:10 pm Post subject: |
|
|
Well, that's rather simple - to load the module, kernel needs to read the disk,
without this module, it can't see it. You'd need an initramfs with that module,
if you'd want to have it outside kernel. |
|
| Back to top |
|
 |
d2_racing Moderator


Joined: 25 Apr 2005 Posts: 12867 Location: Ste-Foy,Canada
|
Posted: Mon Apr 05, 2010 2:28 am Post subject: |
|
|
It's a good thing that you can boot your box  _________________ Sysadmin of Funtoo-Québec.org
Wiki
Signature
IRC on Freenode : #funtoo-quebec |
|
| Back to top |
|
 |
|