Gentoo Archives: gentoo-user

From: Richard Fish <bigfish@××××××××××.org>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] confused udev?
Date: Thu, 17 Nov 2005 14:22:54
Message-Id: 7573e9640511170614q4129191cv27de7f4def6b1e85@mail.gmail.com
In Reply to: Re: [gentoo-user] confused udev? by Jorge Almeida
1 On 11/17/05, Jorge Almeida <jalmeida@××××××××××××.pt> wrote:
2 > $ cat /etc/udev/rules.d/40-my.rules
3 > BUS="scsi", SYSFS{vendor}="PLEXTOR ", SYSFS_model="PlexFlash-2*", NAME="plextor_memstick%n"
4 > BUS="scsi", SYSFS{vendor}="Maxtor 6 ", SYSFS_model="L250R0*", NAME="external_hd%n"
5
6 > SYSFS{model}=="L250R0 "
7 > SYSFS{queue_depth}=="1"
8 > SYSFS{queue_type}=="none"
9 > SYSFS{rev}=="BAH4"
10 > SYSFS{scsi_level}=="3"
11 > SYSFS{state}=="running"
12 > SYSFS{timeout}=="30"
13 > SYSFS{type}=="0"
14 > SYSFS{vendor}=="Maxtor 6"
15
16 Here is a problem...you have an extra space in your vendor string, so
17 the first rule will not match.
18
19 Also, you should be using "==" in your rules, not "=", and
20 SYSFS{model}, not SYSFS_model. I think these latter issues are the
21 reason the plextor rule is matching, because from the udev man page,
22 "=" does not test for equality, it assigns a value to a key.
23
24 So first, cut-n-paste the vendor and model strings from this output
25 into your rule, and change all of the "=" to "==" (except for the NAME
26 setting). Then try setting udev_log=7 in /etc/udev/udev.conf, and
27 watch /var/log/messages when you plug in the drive.
28
29 -Richard
30
31 --
32 gentoo-user@g.o mailing list

Replies

Subject Author
Re: [gentoo-user] confused udev? Jorge Almeida <jalmeida@××××××××××××.pt>