Re: [SLUG] hard drive enclosures and firewire?

From: Ian C. Blenke (icblenke@nks.net)
Date: Tue Oct 03 2006 - 18:23:04 EDT


Eben King wrote:

> I have a usb drive, and it might appear as hda or hde or hdf,
> depending on whether it was on when the computer was booted, or
> whether I've power-cycled it in that boot. Can an automounter
> recognize the _type_ of drive, independent of its device?

Yes.

You can do all kinds of crazy things with udev (though I personally
disagree with that approach). This means you could have
/dev/devicetype/firstdrive as an actual device filename, for example.

Also, once you have /dev/sda for example, you would need to walk through
/proc (/proc/scsi/scsi and /proc/bus/...) to figure out what controller
is presenting the device (or dmesg/kern.log, etc etc). You can't tell
just by looking at the /dev/sda device filename, as those are assigned
on a first come first served basis.

- Ian C. Blenke <ian@blenke.com> <icblenke@nks.net> http://ian.blenke.com/

-----------------------------------------------------------------------
This list is provided as an unmoderated internet service by Networked
Knowledge Systems (NKS). Views and opinions expressed in messages
posted are those of the author and do not necessarily reflect the
official policy or position of NKS or any of its employees.



This archive was generated by hypermail 2.1.3 : Fri Aug 01 2014 - 17:48:59 EDT