Gentoo Archives: gentoo-user

From: Neil Bothwick <neil@××××××××××.uk>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] help with UDEV and USB flash drive
Date: Fri, 09 Jun 2006 10:23:42
Message-Id: 20060609111653.64a97d0c@hactar.digimed.co.uk
In Reply to: Re: [gentoo-user] help with UDEV and USB flash drive by Dirk Heinrichs
1 On Fri, 9 Jun 2006 10:59:13 +0200, Dirk Heinrichs wrote:
2
3 > > That's because you are trying to mount the whole device, not the
4 > > partition.
5 >
6 > Even the whole device should be a block device, shouldn't it?
7
8 Yes it should, it's podd that is appears as a character device.
9
10 > And if it
11 > had a filesystem, you could even mount it, having one partition is as
12 > good as having no partition, at least for Linux.
13
14 It's not the same. A filesystem on a single partition filling the device
15 is not the same as a filesystem on the device itself. Both are possible,
16 and mountable, but not at the same time. I've just checked with with a
17 single partition device to be sure, it didn't work.
18
19 > > BUS=="usb", KERNEL=="sd?1", SYSFS{idProduct}=="0845",
20 > > SYSFS{idVendor}=="08ec", NAME="gigabyte", SYMLINK="%k usb/gigabyte"
21 >
22 > OK, here is what I do :-)
23 >
24 > BUS=="scsi", KERNEL=="sd*", SYSFS{model}=="HardDrive ",
25 > SYSFS{rev}=="1.11", SYSFS{vendor}=="32MB ", SYMLINK="usb/stick%n"
26 >
27 > This will give me nodes for the device itself and its partitions.
28
29 I do that for some drives, but my USB sticks are always a single
30 partition, so I give the name to the partition not the device. I also set
31 NAME and put %k in SYMLINK, because pmount uses the name to create the
32 directory in /media, and I want the device mounted
33 at /media/somethingmeaningful, not /media/sdxn.
34
35
36 --
37 Neil Bothwick
38
39 This fortune soaks up 47 times its own weight in excess memory.

Attachments

File name MIME type
signature.asc application/pgp-signature

Replies

Subject Author
Re: [gentoo-user] help with UDEV and USB flash drive Dirk Heinrichs <ext-dirk.heinrichs@×××××.com>