# udev creates only hda - hdh. How can I get hdo?

## django013

Hello,

i've problems with booting a new installed server (first migration to gentoo).

The (may be temporarily) root is on hdm1 and the raid needs an hdo1.

Do I have to create this devices with mknod or is there a way to configure udev so that it creates the devices at boot-time?

----------

## NeddySeagoon

django013,

The kernel only auto probes for the first 6 IDE interface 0..5, so thats as far as /dev/hdl.

I suspect if you get the kernel to probe for ide6, udev will make the device nodes as requied.

That may need the kernel IDE code to be tweaked.

----------

## django013

Hi NeddySeagoon,

thank you very much for your attention!

But I'm a bit confused about your answer.

On my 'old' Suse system I set up a 2.6.12-kernel from kernel.org with udev active.

That kernel has no patch from Suse or me - and that system has devices from hda until hdt.

So ist this limitation a hardened 'feature', or general a feature of Gentoo?

----------

## NeddySeagoon

django013,

udev makes /dev/ entries for hardware found by the kernel (sometimes with help from other things) according to rules in /etc/udev/rules. I don't see anything there that limits /dev/hdX entries.

The kernel only probes ide0..ide5 inclusive, so it will find at most 12 IDE devices, thats /dev/hdl.

/dev/hdm and /dev/hdo will be on ide6, so for udev to make the /dev/ entries, the kernel needs to probe the controller, or to be otherwise told that ide6 exists.

You can make the node by hand but I suspect you will still have problems.

----------

## django013

 *Quote:*   

> You can make the node by hand but I suspect you will still have problems.

 

Yes, I tried creating the missing devices, but as udev 'mounts' a filesystem at /dev my devices are hidden before the root-device could be mounted. Currently the boot-process breaks at the fsck of /dev/hdm1.

I wondered whether it is possible to cheat udev by rule or trigger ..., but without having a root-device - bad luck.

I'll go to change the order of the controllers, so that I have a root-device and than create an rc-script that creates the devices 'manually'. I think, that's a better way than patching the kernel.

Thank you for your time and your assistance!

----------

## NeddySeagoon

django013,

There is a built in cheat. In /etc/conf.d/rc set RC_DEVICE_TARBALL="yes".

This will preserve manually created /dev/ entries across reboots.

----------

## django013

Hi NeddySeagoon,

thanks for that information.

I got a little step further (without the need of hardware-changes):

Although I was told, that the kernel option 'ide=reverse' was a Suse-expansion, this option works in Gentoo too (I think, because it may be a standard option?).

So the former hdm1 is now hde1. With this setting it is possible to boot and after the boot there are the missing devices hdm, hdo, ...

What still fails is the software raid. mdadm claims that there is no /dev/md0 - I tried to create that with mknod, but stil the same error-message. I'll keep on scratchin...

It's a very hard way (4 me) to change to Gentoo (so many pitfals, I never cared about) - but stil I think, I'm on the right way...

----------

## NeddySeagoon

django013,

ide=reverse is a vanillia kernel option. Its documented in /usr/src/linux/Documentatioin/ either in kernel-parameters.txt or in ide.txt.

It makes the kernel scan the PCI bus before looking for IDE interfaces on the motherboard.

/dev/md0 should be created when the raid modules are loaded.

Reading the kernel code shows that linux/drivers/ide/ide.c contains  

```
* This is the multiple IDE interface driver, as evolved from hd.c.

 * It supports up to MAX_HWIFS IDE interfaces, on one or more IRQs
```

and grepping in /usr/src/linux with 

```
grep -R -B3 MAX_HWIFS ./*
```

shows the constant MAX_HWIFS being defined to be various values for different architectures, usually 6 or 10.

```
dmesg | grep ide
```

includes 

```

[   35.108118] Probing IDE interface ide0...

[   35.619546] Probing IDE interface ide1...

[   37.056266] ide1 at 0x170-0x177,0x376 on irq 15

[   37.057665] Probing IDE interface ide0...

[   37.575346] Probing IDE interface ide2...

[   38.086509] Probing IDE interface ide3...

[   38.597673] Probing IDE interface ide4...

[   39.108837] Probing IDE interface ide5...
```

which shows 6 IDE interfaces getting probed.

If you have more ide interfaces than are probed, you need to edit the define MAX_HWIFS that applies to you so the kernel can deal with more than 6 ide interfaces.

----------

## django013

Hi NeddySeagoon,

thank you for this great response.

On my old Suse-System (with vanilla 2.6.12.3 selfcompiled)  I found this out:

```
:~ # grep 'Probing IDE' /var/log/boot.msg

<7>Probing IDE interface ide0...

<7>Probing IDE interface ide1...

<7>Probing IDE interface ide2...

<7>Probing IDE interface ide3...

<7>Probing IDE interface ide4...

<7>Probing IDE interface ide5...

<7>Probing IDE interface ide6...

<7>Probing IDE interface ide7...

```

Although I succeed booting with 'ide=reverse', I'll keep on investigating about that point (yes, I'm curios).

Currently I'm baking a new kernel, so my feetback will not be so early.

Thank you a lot!

----------

## Zee

try passing ideX=noprobe to Grub/Lilo.

It helped me.

zee

----------

