[TriLUG] finding udev renamed flashkeys

Joseph Mack NA3T jmack at wm7d.net
Sun Apr 12 22:41:48 EDT 2009


On Sun, 12 Apr 2009, Matt Pusateri wrote:

(and Kevin Hunter)

> I would expect when you plugged it in, that you would see it show up in dmesg 
> or in syslog.

yes, it appears as /dev/sda*


> lsusb should show you the device information that you could 
> use to put it in udev rules show it shows up in the same 
> place every time.

I have working udev rules and eg one key shows up as 
/dev/pny* just fine and in /etc/mtab as /dev/pny*, which is 
what I want (usb harddrives appear as /dev/backup* etc). 
However in /proc/partitions or /proc/diskstats it's 
/dev/sda*. I'm logging disk read/writes etc through 
/proc/diskstates, so I want to know which usb drive is
plugged in, rather than the arbitary sd[a..z]* device.

While dmesg is fine for watching the device being plugged 
in, it doesn't help in 2hrs when a script is trying to 
figure out which external devices are doing what disk 
activity.

lsusb doesn't tell me anything about the scsi device 
(/dev/pny* or /dev/sda*)

systool doesn't help either (AFAICT)


Thanks Joe

-- 
Joseph Mack NA3T EME(B,D), FM05lw North Carolina
jmack (at) wm7d (dot) net - azimuthal equidistant map
generator at http://www.wm7d.net/azproj.shtml
Homepage http://www.austintek.com/ It's GNU/Linux!



More information about the TriLUG mailing list