linux-hotplug.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [announce] scsi_id 0.1 - generate unique scsi id
@ 2003-10-22  0:12 Patrick Mansfield
  0 siblings, 0 replies; 4+ messages in thread
From: Patrick Mansfield @ 2003-10-22  0:12 UTC (permalink / raw)
  To: linux-hotplug

[-- Attachment #1: Type: text/plain, Size: 1496 bytes --]

[Augh ... I used the the wrong hotplug devel address again. Already sent
to linux-scsi.]

Attached is version 0.1 of scsi_id, a program to generate a SCSI unique
identifier for a given SCSI device.

It is primarily for use with udev callout config entries. It could also be
used for automatic multi-path configuration.

It generates and uses a temporary dev entry based on the values found in
sysfs dev attributes. This means it does not support SCSI drivers that do
are not currently creating dev entries (st or sg). In addition, for this
to function with st (assuming you have a tape drive that supports page 0x80
or page 0x83) st would have to support SG_IO.

It uses the SG_IO ioctl to send SCSI INQUIRY page 0x80 or page 0x83
commands to the SCSI device.

Requires:

- Linux kernel 2.6

- libsysfs 

No man page yet.

libsysfs 0_2_0 was not installing libsysfs.h or dlist.h, manually copy
those files to /usr/include/sys before compiling.

Build via make and make install.

To use with udev, in short:

Run scsi_id to dump a value, for example, for sda, run:

	scsi_id  -s /block/sda

Take the resulting value (including white space) and use it as the ID in a
udev CALLOUT entry, an exmample /etc/udev/namedev.config entry for one of
my disk drives:

CALLOUT, PROGRAM="/sbin/scsi_id" BUS="scsi", ID="SIBM OEM DCHS09X 68078621" NAME="disk-1"

I have not tried using scsi_id (or udev) via initramfs or initrd.

Please send me any questions, comments or patches.

Thanks!

-- Patrick Mansfield

[-- Attachment #2: scsi_id-0.1.tar.gz --]
[-- Type: application/x-gzip, Size: 19559 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [announce] scsi_id 0.1 - generate unique scsi id
@ 2003-10-22 16:15 Patrick Mansfield
  2003-10-22 16:23 ` Christoph Hellwig
  2003-10-23  7:33 ` Jes Sorensen
  0 siblings, 2 replies; 4+ messages in thread
From: Patrick Mansfield @ 2003-10-22 16:15 UTC (permalink / raw)
  To: linux-hotplug

On Wed, Oct 22, 2003 at 04:52:31PM +0100, Matthew Wilcox wrote:
> On Wed, Oct 22, 2003 at 01:05:21AM -0700, Daniel Stekloff wrote:
> > The headers are being installed into /usr/local/include, I believe this
> > can be configured differently using autoconf tools. If they should be
> > installed elsewhere by default, please let us know.
> > 
> > Patrick told us that we weren't even installing headers. Don't mind me,
> > need more tea. 
> 
> You shouldn't be installing them into the <sys/> namespace, that's
> basically owned by POSIX.  How about <sysfs/> instead?

I incorrectly suggested we should use <sys/>. 

Should we use <linux/>, rather than another new directory?

And sorry for getting the hogplug list address wrong.

-- Patrick Mansfield
wrong.


-------------------------------------------------------
This SF.net email is sponsored by OSDN developer relations
Here's your chance to show off your extensive product knowledge
We want to know what you know. Tell us and you have a chance to win $100
http://www.zoomerang.com/survey.zgi?HRPT1X3RYQNC5V4MLNSV3E54
_______________________________________________
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] 4+ messages in thread

* Re: [announce] scsi_id 0.1 - generate unique scsi id
  2003-10-22 16:15 [announce] scsi_id 0.1 - generate unique scsi id Patrick Mansfield
@ 2003-10-22 16:23 ` Christoph Hellwig
  2003-10-23  7:33 ` Jes Sorensen
  1 sibling, 0 replies; 4+ messages in thread
From: Christoph Hellwig @ 2003-10-22 16:23 UTC (permalink / raw)
  To: linux-hotplug

On Wed, Oct 22, 2003 at 09:15:19AM -0700, Patrick Mansfield wrote:
> Should we use <linux/>, rather than another new directory?

No.  <linux/> is reserved for kernel headers.



-------------------------------------------------------
This SF.net email is sponsored by OSDN developer relations
Here's your chance to show off your extensive product knowledge
We want to know what you know. Tell us and you have a chance to win $100
http://www.zoomerang.com/survey.zgi?HRPT1X3RYQNC5V4MLNSV3E54
_______________________________________________
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] 4+ messages in thread

* Re: [announce] scsi_id 0.1 - generate unique scsi id
  2003-10-22 16:15 [announce] scsi_id 0.1 - generate unique scsi id Patrick Mansfield
  2003-10-22 16:23 ` Christoph Hellwig
@ 2003-10-23  7:33 ` Jes Sorensen
  1 sibling, 0 replies; 4+ messages in thread
From: Jes Sorensen @ 2003-10-23  7:33 UTC (permalink / raw)
  To: linux-hotplug

>>>>> "Patrick" = Patrick Mansfield <patmans@us.ibm.com> writes:

Patrick> On Wed, Oct 22, 2003 at 04:52:31PM +0100, Matthew Wilcox
Patrick> wrote:
>> You shouldn't be installing them into the <sys/> namespace, that's
>> basically owned by POSIX.  How about <sysfs/> instead?

Patrick> I incorrectly suggested we should use <sys/>.

Patrick> Should we use <linux/>, rather than another new directory?

Rule of thumb: any existing hierachy is reserved, either you want to
drop it in header root, ie. /usr/include or /usr/loca/include or you
want to create your own hierachy, <sysfs/> as Matthew suggested looks
like a good candidate to me.

Cheers,
Jes


-------------------------------------------------------
This SF.net email is sponsored by OSDN developer relations
Here's your chance to show off your extensive product knowledge
We want to know what you know. Tell us and you have a chance to win $100
http://www.zoomerang.com/survey.zgi?HRPT1X3RYQNC5V4MLNSV3E54
_______________________________________________
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] 4+ messages in thread

end of thread, other threads:[~2003-10-23  7:33 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-10-22 16:15 [announce] scsi_id 0.1 - generate unique scsi id Patrick Mansfield
2003-10-22 16:23 ` Christoph Hellwig
2003-10-23  7:33 ` Jes Sorensen
  -- strict thread matches above, loose matches on Subject: below --
2003-10-22  0:12 Patrick Mansfield

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).