# [SOLVED] External Harddisk not mounted at boot

## baschni

Hi all,

I've got an external USB-disk, that isn't mounted at boot, though called in fstab:

 *Quote:*   

> /dev/sdb1		/mnt/data	xfs		noatime		0 2

 

When I run 'mount /mnt/data' after startup, it mounts just fine.

Dmesg put's this out at mount time, which seems just fine:

 *Quote:*   

> [   12.513691] sd 4:0:0:0: [sdb] 976773168 512-byte hardware sectors (500108 MB)
> 
> [   12.514441] sd 4:0:0:0: [sdb] Write Protect is off
> 
> [   12.514444] sd 4:0:0:0: [sdb] Mode Sense: 00 38 00 00
> ...

 

Am I overseeing some simple thing? Any idea why it doesn't mount at boot?

Yours,

baschniLast edited by baschni on Sun Aug 30, 2009 8:37 pm; edited 1 time in total

----------

## jongeek

Are XFS and USB compiled as modules or directly into the kernel ?

----------

## baschni

Yes, they are. But the symlink /usr/src/linux doesn't point to the right version, is that import?

----------

## jongeek

Sorry, it wasn't really a yes or no question  :Smile: . 

Yes, they are modules, or yes they are compiled in ?

Assuming you meant they are modules, compile USB and XFS directly into the kernel instead. See if everything works that way. The modules may not have been loaded when fstab is checked for filesystems to mount.

If you really want them as modules, you can change back later. For now, I would focus on trying to find out where the problem lies, and compiling them directly into the kernel will avoid timing problems related to when the modules are loaded by the initscripts (or kmod).

FWIW, I have an external firewire drive that is mounted at boot time, and I build support for it directly into the kernel. The only thing I build as modules are those things I _rarely_ use.

----------

## skrapasor

i bet it's because you start the boot process before the kernel gets a chance to load it. that happened to me. try adding rootdelay=10 to your kernel line in grub.conf.

----------

## baschni

yes, they are compiled in^^

I'll try that with the bootdelay, does it take 10 sec than?

----------

## baschni

boot delay doesn't solve it  :Sad: 

----------

## baschni

I am still having trouble.

At boot time he says:

* Mounting local filesystems

Device /dev/sdb1 doesn't exist!

* Some local filesystems failed to mount

Does anyone have some more ideas? what can I check?

Yours,

baschni

----------

## Apetrini

When system try to mount local disk (reading fstab) the device  /dev/sdb1 is not yet created by kernel.

Are you shure you have all you need to mount a disk (compiled into kernel)?

Because 

```
[12.522421]...
```

 shows that the disk (and partition) is recognized very late in the kernel.

----------

## baschni

Ok, when I hit lsmod after boot I just have my graphics card driver listed, so there's no other module for mounting etc.

So I have XFS compiled into the kernel, support for Host-side USB, usb mass storage support, usb device filesystem, usb announce devices, uhci, ohci, ehci (i just need one, right?) and usb printer support.

Do I need anything else for my harddisk? How do you see, that it's recognized lately? Is [12.522421] some time relative to boot?

Thanks so far,

baschni

----------

## mikkoc

The same happens to both my WD external usb hd.

I never got them to mount automatically via fstab.

Basically they're recognized/initialized way too late, when fstab has been read already.

I solved it by adding the mount command in /etc/conf.d/local.start

----------

## baschni

Thanks, both solutions worked, actually I wrote the rootdelay in a new line under the kernel boot line in grub.conf, but had to write it onto the same line, works great!

Yours,

baschni

----------

