You are not logged in.

#1 2009-07-04 19:39:51

theking2
Banned
From: Romanshorn Switzerland
Registered: 2009-03-04
Posts: 372

mount by UUID fails

I have the following in my fstab

UUID=91bbb7bc-7a99-441c-99a5-fe3d14d5c9c0 / ext4 defaults 0 1
UUID=e30408dd-60a4-4392-886e-2e89d34a9fb2 /boot ext4 defaults 0 1
UUID=e8bf9ec2-6636-41ba-a4b6-3f2fa079b936 /home ext4 defaults 0 1
UUID=46ca8777-a3cc-4ffb-811e-28a2ec303eb5 /server xfs defaults 0 1

The last entry is on a USB harddisk. If I reboot the system like this it claims it cannot find the device with this ID and mounts / read-only. The content of /dev/disk/by-uuid is

lrwxrwxrwx 1 root root 10 2009-07-04 21:26 46ca8777-a3cc-4ffb-811e-28a2ec303eb5 -> ../../sdb2
lrwxrwxrwx 1 root root 10 2009-07-04 21:26 4E30B21E30B20D49 -> ../../sdb1
lrwxrwxrwx 1 root root 10 2009-07-04 21:25 91bbb7bc-7a99-441c-99a5-fe3d14d5c9c0 -> ../../sda2
lrwxrwxrwx 1 root root 10 2009-07-04 21:25 a364d511-9ff7-4619-a5de-51a3333f2f4e -> ../../sda6
lrwxrwxrwx 1 root root 10 2009-07-04 21:25 e30408dd-60a4-4392-886e-2e89d34a9fb2 -> ../../sda1
lrwxrwxrwx 1 root root 10 2009-07-04 21:25 e8bf9ec2-6636-41ba-a4b6-3f2fa079b936 -> ../../sda5

If I comment out the line with 46ca8777-a3cc-4ffb-811e-28a2ec303eb5 the system boots fine and I can do a

mount /dev/sdb2 /server

without a problem.

How do I configure the fstab to allow a boot to find and mount the partition on an external harddisk?

Last edited by theking2 (2009-07-04 19:41:06)


archlinux on a Gigabyte C1037UN-EU, 16GiB
a Promise  PDC40718 based ZFS set
root on a Samsung SSD PB22-J
running LogitechMediaServer(-git), Samba, MiniDLNA, TOR

Offline

#2 2009-07-04 19:52:07

toad
Member
From: if only I knew
Registered: 2008-12-22
Posts: 1,775
Website

Re: mount by UUID fails

Have you tried to mount it manually? Normally mounting gets done before hal kicks in, so mounting via fstab shouldn't work.


never trust a toad...
::Grateful ArchDonor::
::Grateful Wikipedia Donor::

Offline

#3 2009-07-04 20:01:23

darthaxul
Member
Registered: 2008-09-24
Posts: 156

Re: mount by UUID fails

just run `dumpe2fs /dev/sdx |head` and make sure the UUID's match what ur mounting.

Offline

#4 2009-07-04 20:24:34

theking2
Banned
From: Romanshorn Switzerland
Registered: 2009-03-04
Posts: 372

Re: mount by UUID fails

toad wrote:

Have you tried to mount it manually? Normally mounting gets done before hal kicks in, so mounting via fstab shouldn't work.

mount /dev/sdb2 /server

works like a breeze. But I want it to mount on boot and/or connect. Or am I pushing envelopes here?


archlinux on a Gigabyte C1037UN-EU, 16GiB
a Promise  PDC40718 based ZFS set
root on a Samsung SSD PB22-J
running LogitechMediaServer(-git), Samba, MiniDLNA, TOR

Offline

#5 2009-07-04 20:30:07

theking2
Banned
From: Romanshorn Switzerland
Registered: 2009-03-04
Posts: 372

Re: mount by UUID fails

darthaxul wrote:

just run `dumpe2fs /dev/sdx |head` and make sure the UUID's match what ur mounting.

ehm, what does

dumpe2fs 1.41.5 (23-Apr-2009)
dumpe2fs: Bad magic number in super-block while trying to open /dev/sdb2
Couldn't find valid filesystem superblock.

mean?


archlinux on a Gigabyte C1037UN-EU, 16GiB
a Promise  PDC40718 based ZFS set
root on a Samsung SSD PB22-J
running LogitechMediaServer(-git), Samba, MiniDLNA, TOR

Offline

#6 2009-07-04 20:40:19

darthaxul
Member
Registered: 2008-09-24
Posts: 156

Re: mount by UUID fails

I dont know.
try running e2fsck -pfv /dev/sdb2

Offline

#7 2009-07-05 08:35:58

theking2
Banned
From: Romanshorn Switzerland
Registered: 2009-03-04
Posts: 372

Re: mount by UUID fails

There is nothing wrong with the drive or the FS. I can mount it manually just fine. I want it to mount when I connect it or when I boot the OS.


archlinux on a Gigabyte C1037UN-EU, 16GiB
a Promise  PDC40718 based ZFS set
root on a Samsung SSD PB22-J
running LogitechMediaServer(-git), Samba, MiniDLNA, TOR

Offline

#8 2009-07-05 08:41:16

toad
Member
From: if only I knew
Registered: 2008-12-22
Posts: 1,775
Website

Re: mount by UUID fails

If you insist on keeping it in the fstab a mount -a after hal has come up will do it.


never trust a toad...
::Grateful ArchDonor::
::Grateful Wikipedia Donor::

Offline

#9 2009-07-05 09:39:42

theking2
Banned
From: Romanshorn Switzerland
Registered: 2009-03-04
Posts: 372

Re: mount by UUID fails

toad wrote:

If you insist on keeping it in the fstab a mount -a after hal has come up will do it.

interesting question, I don't. I just want it to be available (mounted)  when connected


archlinux on a Gigabyte C1037UN-EU, 16GiB
a Promise  PDC40718 based ZFS set
root on a Samsung SSD PB22-J
running LogitechMediaServer(-git), Samba, MiniDLNA, TOR

Offline

#10 2009-07-06 19:20:06

theking2
Banned
From: Romanshorn Switzerland
Registered: 2009-03-04
Posts: 372

Re: mount by UUID fails

It even get more weird.
I commented out the line associated with the external harddisk. When I boot with the harddisk connected it claims that there is a kernel parameter error and mounts /dev/sda1 in / readonly. With the harddisk detached during boot everything is fine. The external harddisk has no bootable partitions and in the bios is marked as the second hd the first containing the proper boot environment.
So on when I have my bright moments I think of detached the harddisk before (re) boot and eventually mount it manually.

JK


archlinux on a Gigabyte C1037UN-EU, 16GiB
a Promise  PDC40718 based ZFS set
root on a Samsung SSD PB22-J
running LogitechMediaServer(-git), Samba, MiniDLNA, TOR

Offline

#11 2009-07-06 22:21:33

Ranguvar
Member
Registered: 2008-08-12
Posts: 2,545

Re: mount by UUID fails

Try using /dev/disk/by-uuid/UUIDHERE instead of UUID=UUIDHERE. That sometimes works for me.

Offline

Board footer

Powered by FluxBB