From: Douglas Gilbert <dougg@torque.net>
To: Bryan Henderson <hbryan@us.ibm.com>
Cc: Rock Gordon <rockgordon@yahoo.com>, linux-scsi@vger.kernel.org
Subject: Re: WWN on FC LUN targets
Date: Sun, 01 Aug 2004 19:05:50 +1000 [thread overview]
Message-ID: <410CB26E.7060109@torque.net> (raw)
In-Reply-To: <OFD7E2C657.B39E37CA-ON88256EDF.00034E54-88256EDF.0004E839@us.ibm.com>
Bryan Henderson wrote:
>>I am looking at ways to find out particular WWN (world
>>wide names) for SCSI target LUNs
>
>
> LUNS don't actually have fibre channel WWNs. And neither do SCSI logical
> units, which is probably what you meant (a LUN is a logical unit number).
> WWNs come in two flavors - World Wide Node Name (WWNN), which identifies a
> SCSI target, and World Wide Port Name (WWPN), which identifies a port on a
> target. Neither of those is what you want, since you probably have
> multiple logical units per target.
>
> If you're like most FC users, your LUNs aren't stable even within a
> target, so you can't use a combination of WWNN and LUN either.
>
> So what people use is either SCSI device serial number or SCSI device ID.
> The latter is newer and better. There are device IDs for targets, ports,
> and logical units. There are device IDs in each of various name spaces,
> some defined by public standards. You can read all about that in SCSI
> specifications. Device IDs are part of the Vital Product Data (VPD).
>
> The basic programming interface to get that information is the SCSI
> INQUIRY command.
>
> People have written programs to do the INQUIRY and give you the results in
> usable form and even create the device special files named after the
> device IDs. I'm afraid I can't name one at the moment, but I hope someone
> else on the list chimes in with the specifics.
<snip>
The scsi_id program by Patrick Mansfield queries a SCSI device's
identification and serial number vital product data (VPD) pages
and produces a unique number. It is meant to be used in conjunction
with udev (a dynamic device node creation, naming and removal facility
based on the hotplug subsystem in the lk 2.6 series) to create device
(and partition) node names according to user specified rules.
Several versions can be found at this url:
http://www-124.ibm.com/storageio/scsi_id/
The sg_inq utility in the sg3_utils package (version 1.07) has
a '-i' option that will decode all the "identification descriptors"
in the device identification VPD page (0x83) for the nominated device.
That information in conjunction with some of the explanations in
this thread may show you what identifiers, if any, are available.
The unit serial number page can be queried with
'sg_inq -o=80 /dev/sda'.
sg3_utils can be found at: http://www.torque.net/sg
SPC-3 (SCSI Primary Commands) can be found http://www.t10.org
The most recent draft is version 19 and section 7.6.4 and 7.6.11
are relevant.
Doug Gilbert
next prev parent reply other threads:[~2004-08-01 9:06 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-07-27 20:55 WWN on FC LUN targets Rock Gordon
2004-07-28 0:54 ` Bryan Henderson
2004-08-01 9:05 ` Douglas Gilbert [this message]
2004-08-04 17:04 ` Rock Gordon
-- strict thread matches above, loose matches on Subject: below --
2004-07-28 14:22 David Peterson (Eng)
2004-07-28 15:46 ` Rock Gordon
2004-07-28 17:09 ` Bryan Henderson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=410CB26E.7060109@torque.net \
--to=dougg@torque.net \
--cc=hbryan@us.ibm.com \
--cc=linux-scsi@vger.kernel.org \
--cc=rockgordon@yahoo.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox