[TriLUG] generic code to discover fibre channel disks by LUN (and whatever other information is needed)

Andrew Ball anball at gmail.com
Thu Jun 21 23:57:44 EDT 2007


Good evening.

I'd like to find a way to discover fibre channel logical drives by LUN and
whatever other information
is necessary.

I think two options for the information to use other than the LUN are

-- the world wide port name of any of the controllers connected to the
logical drive
-- the world wide name of one of the hba's connected to the drive (don't
want to use this)
-- others?

I can identify things by their scsi_id, but that doesn't map to the LUN's
very well, if at all.

I see a graph of the scsi bus(es) with ls_scsi.  I could probably combine
that with some
sort of algorithm to determine which adapters are fibre channel.  Then I
could look
for a LUN on each, using scsi_id to decide which disks are the same.

Does that approach make sense?  Any examples or other ideas?

Thanks for your help.
Andrew

-- 
=======================
Andrew D. Ball
勃安足


More information about the TriLUG mailing list