* Re: Does sysfs really provides persistent hardware path to devices? [not found] ` <20030924211823.GA11234@kroah.com> @ 2004-01-17 20:34 ` Andrey Borzenkov 2004-01-17 21:34 ` Greg KH 2004-01-19 13:08 ` Olaf Hering 0 siblings, 2 replies; 10+ messages in thread From: Andrey Borzenkov @ 2004-01-17 20:34 UTC (permalink / raw) To: Greg KH; +Cc: jw schultz, linux-kernel, linux-hotplug-devel On Thursday 25 September 2003 01:18, Greg KH wrote: > On Sun, Aug 31, 2003 at 02:54:06PM +0400, Andrey Borzenkov wrote: > > On Tuesday 19 August 2003 00:42, Greg KH wrote: > > > On Mon, Aug 18, 2003 at 10:21:22AM +0400, "Andrey Borzenkov" wrote: > > > > just to show what I expected from sysfs - here is entry from Solaris > > > > /devices: > > > > > > > > brw-r----- 1 root sys 32,240 Jan 24 2002 > > > > /devices/pci@16,4000/scsi@5,1/sd@0,0:a > > > > > > > > this entry identifies disk partition 0 on drive with SCSI ID 0, LUN 0 > > > > connected to bus 1 of controller in slot 5 of PCI bus identified > > > > by 16. Now you can use whatever policy you like to give human > > > > meaningful name to this entry. And if you have USB it will continue > > > > further giving you exact topology starting from the root of your > > > > device tree. > > > > > > > > and this path does not contain single logical id so it is not subject > > > > to change if I add the same controller somewhere else. > > > > > > > > hopefully it clarifies what I mean ... > > > > > > Hm, a bit. First, have you looked at what sysfs provides? Here's one > > > of my machines and tell me if it has all the info you are looking for: > > > > > > $ tree /sys/bus/scsi/ > > > /sys/bus/scsi/ > > > > > > |-- devices > > > | `-- 0:0:0:0 -> > > > | ../../../devices/pci0000:00/0000:00:1e.0/0000:02:05.0/host0/0:0:0:0 > > > > ^ ^unstable > > Heh, so are the pci ids in that link too :) > I am not sure if you are just making fun here. No, in _this_ link pci ids are not unstable because I do not have hotpug PCI. But SCSI hosts are unstable: {pts/0}% LC_ALL=C ll /sys/class/scsi_host/*/device lrwxrwxrwx 1 root root 71 Jan 17 22:59 /sys/class/scsi_host/host7/device -> ../../../devices/pci0000:00/0000:00:1f.4/usb2/2-2/2-2.4/2-2.4:1.0/host7/ lrwxrwxrwx 1 root root 29 Jan 17 23:19 /sys/class/scsi_host/host8/device -> ../../../devices/legacy/host8/ after unplugging and replugging USB stick: pts/0}% LC_ALL=C ll /sys/class/scsi_host/*/device lrwxrwxrwx 1 root root 29 Jan 17 23:19 /sys/class/scsi_host/host8/device -> ../../../devices/legacy/host8/ lrwxrwxrwx 1 root root 71 Jan 17 23:25 /sys/class/scsi_host/host9/device -> ../../../devices/pci0000:00/0000:00:1f.4/usb2/2-2/2-2.4/2-2.4:1.0/host9/ host7 became host9 [... skipped as obsolete now...] > > And yes, we should add wild card matching for topology rules, it's on > the todo list, I haven't had much time to work on udev lately. > > > > Hope this helps, > > > > Well, we did not move a tiny bit since the beginning of this thread :) > > You still did not show me namedev configuration that implements > > persistent name for a device based on its physical location :))) > > Ok, do you have any other ideas of how to do this? > given current sysfs implementation - using wildcards remains the only solution. I for now am using this trivial script: pts/0}% cat /etc/udev/scripts/removables #!/usr/bin/perl my $devpath, $base; $base = $1 if ($ARGV[0] =~ /(.*\D)\d*$/); $devpath = readlink "/sys/block/$base/device"; if ($devpath =~ m|/devices/pci0000:00/0000:00:1f.4/usb2/2-2/2-2.4/2-2.4:1.0/host\d+/\d+:0:0:0|) { print "flash0"; } elsif ($devpath =~ m|/devices/pci0000:00/0000:00:1f.4/usb2/2-2/2-2.1/2-2.1:1.0/host\d+/\d+:0:0:0|) { print "flash1"; } elsif ($devpath =~ m|/devices/legacy/host\d+/\d+:0:4:0|) { print "jaz"; } else { exit(1); } 1; with config KERNEL="sd*" PROGRAM="/etc/udev/scripts/removables %k" SYMLINK="%c/%D" > And patches for udev are always welcome :) > as example shows it probably can be done without serious patches. The only problem is to make devpath available; at this point udev already computed it. If you think it makes sense, patch will follow. regards -andrey ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Does sysfs really provides persistent hardware path to devices? 2004-01-17 20:34 ` Does sysfs really provides persistent hardware path to devices? Andrey Borzenkov @ 2004-01-17 21:34 ` Greg KH 2004-01-18 1:03 ` Kay Sievers ` (3 more replies) 2004-01-19 13:08 ` Olaf Hering 1 sibling, 4 replies; 10+ messages in thread From: Greg KH @ 2004-01-17 21:34 UTC (permalink / raw) To: Andrey Borzenkov; +Cc: jw schultz, linux-kernel, linux-hotplug-devel On Sat, Jan 17, 2004 at 11:34:13PM +0300, Andrey Borzenkov wrote: > On Thursday 25 September 2003 01:18, Greg KH wrote: Heh, nothing like a long time between responses :) > > On Sun, Aug 31, 2003 at 02:54:06PM +0400, Andrey Borzenkov wrote: > > > On Tuesday 19 August 2003 00:42, Greg KH wrote: > > > > On Mon, Aug 18, 2003 at 10:21:22AM +0400, "Andrey Borzenkov" wrote: > > > > > just to show what I expected from sysfs - here is entry from Solaris > > > > > /devices: > > > > > > > > > > brw-r----- 1 root sys 32,240 Jan 24 2002 > > > > > /devices/pci@16,4000/scsi@5,1/sd@0,0:a > > > > > > > > > > this entry identifies disk partition 0 on drive with SCSI ID 0, LUN 0 > > > > > connected to bus 1 of controller in slot 5 of PCI bus identified > > > > > by 16. Now you can use whatever policy you like to give human > > > > > meaningful name to this entry. And if you have USB it will continue > > > > > further giving you exact topology starting from the root of your > > > > > device tree. > > > > > > > > > > and this path does not contain single logical id so it is not subject > > > > > to change if I add the same controller somewhere else. > > > > > > > > > > hopefully it clarifies what I mean ... > > > > > > > > Hm, a bit. First, have you looked at what sysfs provides? Here's one > > > > of my machines and tell me if it has all the info you are looking for: > > > > > > > > $ tree /sys/bus/scsi/ > > > > /sys/bus/scsi/ > > > > > > > > |-- devices > > > > | `-- 0:0:0:0 -> > > > > | ../../../devices/pci0000:00/0000:00:1e.0/0000:02:05.0/host0/0:0:0:0 > > > > > > ^ ^unstable > > > > Heh, so are the pci ids in that link too :) > > > > I am not sure if you are just making fun here. No, in _this_ link pci ids are > not unstable because I do not have hotpug PCI. Your PCI ids could change over reboots for a number of different reasons (bios changes, adding or removing cards, phase of the moon, etc.) My point is, PCI ids can not be guananteed to be stable for everyone. > But SCSI hosts are unstable: Exactly. > given current sysfs implementation - using wildcards remains the only > solution. I for now am using this trivial script: You know that udev now supports wildcards in its pattern matching, right? > pts/0}% cat /etc/udev/scripts/removables > #!/usr/bin/perl > > my $devpath, $base; > > $base = $1 if ($ARGV[0] =~ /(.*\D)\d*$/); > $devpath = readlink "/sys/block/$base/device"; > > if ($devpath =~ > m|/devices/pci0000:00/0000:00:1f.4/usb2/2-2/2-2.4/2-2.4:1.0/host\d+/\d+:0:0:0|) > { > print "flash0"; ick, isn't there a unique sysfs id in this location for this device that you can query off of? model? vendor? scsi uuid? > } elsif ($devpath =~ > m|/devices/pci0000:00/0000:00:1f.4/usb2/2-2/2-2.1/2-2.1:1.0/host\d+/\d+:0:0:0|) > { > print "flash1"; > } elsif ($devpath =~ m|/devices/legacy/host\d+/\d+:0:4:0|) { > print "jaz"; > } else { > exit(1); > } > > 1; > > with config > > KERNEL="sd*" PROGRAM="/etc/udev/scripts/removables %k" SYMLINK="%c/%D" I just removed %D from udev too :) > > And patches for udev are always welcome :) > > > > as example shows it probably can be done without serious patches. The only > problem is to make devpath available; at this point udev already computed it. > If you think it makes sense, patch will follow. I could see making devpath available as a % modifier. thanks, greg k-h ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Does sysfs really provides persistent hardware path to devices? 2004-01-17 21:34 ` Greg KH @ 2004-01-18 1:03 ` Kay Sievers 2004-01-18 14:05 ` Kay Sievers ` (2 subsequent siblings) 3 siblings, 0 replies; 10+ messages in thread From: Kay Sievers @ 2004-01-18 1:03 UTC (permalink / raw) To: linux-hotplug On Sat, Jan 17, 2004 at 01:34:16PM -0800, Greg KH wrote: > On Sat, Jan 17, 2004 at 11:34:13PM +0300, Andrey Borzenkov wrote: > > as example shows it probably can be done without serious patches. The only > > problem is to make devpath available; at this point udev already computed it. > > If you think it makes sense, patch will follow. > > I could see making devpath available as a % modifier. It's available in the environment. PROGRAM="/bin/sh -c set>/tmp/set" shows: ACTIONd DEVPATH=/class/video4linux/video0 DIRSTACK=() EUID=0 GROUPS=() HOME=/ ... thanks, Kay ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Does sysfs really provides persistent hardware path to devices? 2004-01-17 21:34 ` Greg KH 2004-01-18 1:03 ` Kay Sievers @ 2004-01-18 14:05 ` Kay Sievers 2004-01-19 19:51 ` Greg KH 2004-03-14 19:25 ` Horst von Brand 3 siblings, 0 replies; 10+ messages in thread From: Kay Sievers @ 2004-01-18 14:05 UTC (permalink / raw) To: linux-hotplug On Sun, Jan 18, 2004 at 02:03:12AM +0100, Kay Sievers wrote: > On Sat, Jan 17, 2004 at 01:34:16PM -0800, Greg KH wrote: > > On Sat, Jan 17, 2004 at 11:34:13PM +0300, Andrey Borzenkov wrote: > > > as example shows it probably can be done without serious patches. The only > > > problem is to make devpath available; at this point udev already computed it. > > > If you think it makes sense, patch will follow. > > > > I could see making devpath available as a % modifier. > > It's available in the environment. PROGRAM="/bin/sh -c set>/tmp/set" shows: > > ACTIONd > DEVPATH=/class/video4linux/video0 > DIRSTACK=() > EUID=0 > GROUPS=() > HOME=/ > ... Oh, sorry, better to read the whole text :) You mean the "device" path, right? Kay ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Does sysfs really provides persistent hardware path to devices? 2004-01-17 21:34 ` Greg KH 2004-01-18 1:03 ` Kay Sievers 2004-01-18 14:05 ` Kay Sievers @ 2004-01-19 19:51 ` Greg KH 2004-03-14 19:25 ` Horst von Brand 3 siblings, 0 replies; 10+ messages in thread From: Greg KH @ 2004-01-19 19:51 UTC (permalink / raw) To: linux-hotplug On Sun, Jan 18, 2004 at 03:05:18PM +0100, Kay Sievers wrote: > On Sun, Jan 18, 2004 at 02:03:12AM +0100, Kay Sievers wrote: > > On Sat, Jan 17, 2004 at 01:34:16PM -0800, Greg KH wrote: > > > On Sat, Jan 17, 2004 at 11:34:13PM +0300, Andrey Borzenkov wrote: > > > > as example shows it probably can be done without serious patches. The only > > > > problem is to make devpath available; at this point udev already computed it. > > > > If you think it makes sense, patch will follow. > > > > > > I could see making devpath available as a % modifier. > > > > It's available in the environment. PROGRAM="/bin/sh -c set>/tmp/set" shows: > > > > ACTIONd > > DEVPATH=/class/video4linux/video0 > > DIRSTACK=() > > EUID=0 > > GROUPS=() > > HOME=/ > > ... > > Oh, sorry, better to read the whole text :) > You mean the "device" path, right? No, I think he wanted DEVPATH, or that's what I thought he ment... thanks, greg k-h ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Does sysfs really provides persistent hardware path to devices? 2004-01-17 21:34 ` Greg KH ` (2 preceding siblings ...) 2004-01-19 19:51 ` Greg KH @ 2004-03-14 19:25 ` Horst von Brand 3 siblings, 0 replies; 10+ messages in thread From: Horst von Brand @ 2004-03-14 19:25 UTC (permalink / raw) To: Andrey Borzenkov; +Cc: linux-kernel, linux-hotplug-devel Andrey Borzenkov <arvidjaar@mail.ru> said: [...] > I am trying to assign name for a USB slot on my PCs front so that when I > plug in USB stick or USB drive or whatever I get the same name. Always. Not necessary: You can mount by volume label, or UUID (Yes, need a sane filesystem for that... and MS-DOS ones aren't. Sorry.) Dangerous: You plug a _different_ USB stick in, and think it is the same. Besides, plugging your drive in "the same place" on USB is useful today, with 1 or 2 conectors. Add hubs, and you are talking about hundreds of places... better concentrate on getting the machine keep track of bureaucratic details. -- Dr. Horst H. von Brand User #22616 counter.li.org Departamento de Informatica Fono: +56 32 654431 Universidad Tecnica Federico Santa Maria +56 32 654239 Casilla 110-V, Valparaiso, Chile Fax: +56 32 797513 ------------------------------------------------------- This SF.Net email is sponsored by: IBM Linux Tutorials Free Linux tutorial presented by Daniel Robbins, President and CEO of GenToo technologies. Learn everything from fundamentals to system administration.http://ads.osdn.com/?ad_id\x1470&alloc_id638&op=click _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Does sysfs really provides persistent hardware path to devices? 2004-01-17 20:34 ` Does sysfs really provides persistent hardware path to devices? Andrey Borzenkov 2004-01-17 21:34 ` Greg KH @ 2004-01-19 13:08 ` Olaf Hering 2004-01-19 13:59 ` Andries Brouwer 2004-03-14 11:53 ` Andrey Borzenkov 1 sibling, 2 replies; 10+ messages in thread From: Olaf Hering @ 2004-01-19 13:08 UTC (permalink / raw) To: Andrey Borzenkov; +Cc: Greg KH, jw schultz, linux-kernel, linux-hotplug-devel On Sat, Jan 17, Andrey Borzenkov wrote: > > > Well, we did not move a tiny bit since the beginning of this thread :) > > > You still did not show me namedev configuration that implements > > > persistent name for a device based on its physical location :))) > > > > Ok, do you have any other ideas of how to do this? > > > > given current sysfs implementation - using wildcards remains the only > solution. I for now am using this trivial script: > > pts/0}% cat /etc/udev/scripts/removables > #!/usr/bin/perl > > my $devpath, $base; > > $base = $1 if ($ARGV[0] =~ /(.*\D)\d*$/); > $devpath = readlink "/sys/block/$base/device"; > > if ($devpath =~ > m|/devices/pci0000:00/0000:00:1f.4/usb2/2-2/2-2.4/2-2.4:1.0/host\d+/\d+:0:0:0|) > { > print "flash0"; > } elsif ($devpath =~ > m|/devices/pci0000:00/0000:00:1f.4/usb2/2-2/2-2.1/2-2.1:1.0/host\d+/\d+:0:0:0|) > { > print "flash1"; > } elsif ($devpath =~ m|/devices/legacy/host\d+/\d+:0:4:0|) { > print "jaz"; > } else { > exit(1); > } I'm not sure what you are trying to do. Working with the 'physical location' of removeable devices will probably fail. The usb-storage devices here have a serial field, I really hope it is unique, use it. -- USB is for mice, FireWire is for men! sUse lINUX ag, n√úRNBERG ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Does sysfs really provides persistent hardware path to devices? 2004-01-19 13:08 ` Olaf Hering @ 2004-01-19 13:59 ` Andries Brouwer 2004-01-19 14:04 ` Olaf Hering 2004-03-14 11:53 ` Andrey Borzenkov 1 sibling, 1 reply; 10+ messages in thread From: Andries Brouwer @ 2004-01-19 13:59 UTC (permalink / raw) To: Olaf Hering Cc: Andrey Borzenkov, Greg KH, jw schultz, linux-kernel, linux-hotplug-devel On Mon, Jan 19, 2004 at 02:08:17PM +0100, Olaf Hering wrote: > ... Working with the 'physical > location' of removeable devices will probably fail. The usb-storage > devices here have a serial field, I really hope it is unique, use it. Too optimistic. I have several devices with serial number 0. ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Does sysfs really provides persistent hardware path to devices? 2004-01-19 13:59 ` Andries Brouwer @ 2004-01-19 14:04 ` Olaf Hering 0 siblings, 0 replies; 10+ messages in thread From: Olaf Hering @ 2004-01-19 14:04 UTC (permalink / raw) To: Andries Brouwer Cc: Andrey Borzenkov, Greg KH, jw schultz, linux-kernel, linux-hotplug-devel On Mon, Jan 19, Andries Brouwer wrote: > On Mon, Jan 19, 2004 at 02:08:17PM +0100, Olaf Hering wrote: > > > ... Working with the 'physical > > location' of removeable devices will probably fail. The usb-storage > > devices here have a serial field, I really hope it is unique, use it. > > Too optimistic. > I have several devices with serial number 0. Nice... Is 'serial' empty, or does it just have '0' in it? And would it also fail to use vendor/device id for these beasts? -- USB is for mice, FireWire is for men! sUse lINUX ag, n√úRNBERG ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Does sysfs really provides persistent hardware path to devices? 2004-01-19 13:08 ` Olaf Hering 2004-01-19 13:59 ` Andries Brouwer @ 2004-03-14 11:53 ` Andrey Borzenkov 1 sibling, 0 replies; 10+ messages in thread From: Andrey Borzenkov @ 2004-03-14 11:53 UTC (permalink / raw) To: Olaf Hering; +Cc: Greg KH, jw schultz, linux-kernel, linux-hotplug-devel On Monday 19 January 2004 16:08, Olaf Hering wrote: > On Sat, Jan 17, Andrey Borzenkov wrote: > > > > Well, we did not move a tiny bit since the beginning of this thread > > > > :) You still did not show me namedev configuration that implements > > > > persistent name for a device based on its physical location :))) > > > > > > Ok, do you have any other ideas of how to do this? > > > > given current sysfs implementation - using wildcards remains the only > > solution. I for now am using this trivial script: > > > > pts/0}% cat /etc/udev/scripts/removables > > #!/usr/bin/perl > > > > my $devpath, $base; > > > > $base = $1 if ($ARGV[0] =~ /(.*\D)\d*$/); > > $devpath = readlink "/sys/block/$base/device"; > > > > if ($devpath =~ > > m|/devices/pci0000:00/0000:00:1f.4/usb2/2-2/2-2.4/2-2.4:1.0/host\d+/\d+:0 > >:0:0|) { > > print "flash0"; > > } elsif ($devpath =~ > > m|/devices/pci0000:00/0000:00:1f.4/usb2/2-2/2-2.1/2-2.1:1.0/host\d+/\d+:0 > >:0:0|) { > > print "flash1"; > > } elsif ($devpath =~ m|/devices/legacy/host\d+/\d+:0:4:0|) { > > print "jaz"; > > } else { > > exit(1); > > } > > I'm not sure what you are trying to do. I am trying to assign name for a USB slot on my PCs front so that when I plug in USB stick or USB drive or whatever I get the same name. Always. > Working with the 'physical > location' of removeable devices will probably fail. why? The 'physical location' is the only thing that is unlikely to change unless you physically change you hardware. Anyway - it appears that udev (as of 022 now) still does not support doing it. Once more - I want to make sure that SCSI disk plugged in specific USB slot (that does not ever change) always gets the same name. So that I always know how to access it. naive user would think that something like KERNEL="sd*" BUS="usb" PLACE="2.4:1.0" SYMLINK="flash0/sd%n" would work. Surely it does not. When udev sees "sd*" it does not see bus USB. When udev sees bus USB it does not see "sd*". It does (probably) see sd* on bus SCSI but it does not help me in any way because I have no way to associate SCSI ID with USB port. While kernel does know that "sda" is a child of USB port 2.4:0.1 I do not see any way to express it in udev. Could somebody explain what am I doing wrong. Thank you. > The usb-storage > devices here have a serial field, I really hope it is unique, use it. Sigh ... let me quote: > I have 6 different firewire hard drives, and an iPod, a usb stick, a usb > stick/camera combo, and a bunch of flash memory products (CF, SM, SD) so > such a thing would be incredibly useful to me. I'm always modifying my > fstab to keep things in order. so you suggest him to add every device separately? And if he has half a dozen friends having half a dozen devices each - do you suggest adding yet another 40 lines for all of them? And keep it in sync with all updates and upgrades? On the contrary he likely has just a couple of USB ports and one firewire and he just needs three lines for *any* device which is ever going to be plugged in. Or he would need if it was supported. thank you -andrey ------------------------------------------------------- This SF.Net email is sponsored by: IBM Linux Tutorials Free Linux tutorial presented by Daniel Robbins, President and CEO of GenToo technologies. Learn everything from fundamentals to system administration.http://ads.osdn.com/?ad_id\x1470&alloc_id638&op=click _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel ^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2004-03-14 19:25 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <E19odOM-000NwL-00.arvidjaar-mail-ru@f22.mail.ru>
[not found] ` <200308311453.00122.arvidjaar@mail.ru>
[not found] ` <20030924211823.GA11234@kroah.com>
2004-01-17 20:34 ` Does sysfs really provides persistent hardware path to devices? Andrey Borzenkov
2004-01-17 21:34 ` Greg KH
2004-01-18 1:03 ` Kay Sievers
2004-01-18 14:05 ` Kay Sievers
2004-01-19 19:51 ` Greg KH
2004-03-14 19:25 ` Horst von Brand
2004-01-19 13:08 ` Olaf Hering
2004-01-19 13:59 ` Andries Brouwer
2004-01-19 14:04 ` Olaf Hering
2004-03-14 11:53 ` Andrey Borzenkov
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).