Operating System - HP-UX
1835215 Members
2207 Online
110078 Solutions
New Discussion

Re: hardware address and nport id mapping

 
SOLVED
Go to solution
Sunny Jaisinghani
Trusted Contributor

hardware address and nport id mapping

Hello all,

I have a query
I would like to know how to find out the hardware address of the device connected to the fiber channel adapter from the nport_id

if the nport_id is 0x20200
then what will be the hardware address????
consider the adapter address to be 0/0/12/0/0

the format of the hardware address according to my finding from a HP document http://docs.hp.com/en/A6795-90006/A6795-90006.pdf is

0/0/12/0/0.domain.area.port.bus.target.lun

Awaiting ur reply

Thanks
26 REPLIES 26
Torsten.
Acclaimed Contributor

Re: hardware address and nport id mapping

What storage device and hardware path we are talking about? More details please.

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
Sunny Jaisinghani
Trusted Contributor

Re: hardware address and nport id mapping

I am talking about storage devices such as disks and tapes connected to the Fiber channel Mass storage adapter through the controllers

I need to know how to convert the nport id to a hardware address????

I refered the document
http://docs.hp.com/en/A6795-90006/A6795-90006.pdf

but was not able to convert the nport id to a correct hardware path.
Sunny Jaisinghani
Trusted Contributor

Re: hardware address and nport id mapping

Can anyone please help me with above concept.
Torsten.
Acclaimed Contributor

Re: hardware address and nport id mapping

The hardware path inside the server to the slot, the HBA, the switch and finally the LUN will influence the hardware path to the device. It also depends on the topology. Switched fabrics are different to arbitrated loops. There are different rules for different switches too.
This all applies to the "legacy" path.
"New" pathes used in 11.31 are totally different (based on WWID's).

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
Sunny Jaisinghani
Trusted Contributor

Re: hardware address and nport id mapping

how do i go along in finding all the details that u mentioned in ur post.
i mean to say which topology and which switch.

i don't have access to the physical server.
Torsten.
Acclaimed Contributor

Re: hardware address and nport id mapping

An example from ioscan:

disk 2 1/0/8/1/0/4/0.13.0.0.0.0.7 sdisk CLAIMED DEVICE
HP HSV200
/dev/dsk/c2t0d7 /dev/rdsk/c2t0d7
/dev/dsk/c2t0d7s1 /dev/rdsk/c2t0d7s1
/dev/dsk/c2t0d7s2 /dev/rdsk/c2t0d7s2
/dev/dsk/c2t0d7s3 /dev/rdsk/c2t0d7s3


I already know the system model and the slot location, the path to the HBA FC port is

1/0/8/1/0/4/0

Now I know the switch type (B-series - you have to inspect it) and the domail ID (13). The (EVA) storage is connected to port 0, the presented vdisk is LUN 7.

So I know all I need to find the device.

As mentioned before, for *old* loop topologies this is very different.

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
Torsten.
Acclaimed Contributor

Re: hardware address and nport id mapping

One more example:

disk 30 1/0/8/1/0/4/0.13.4.0.0.1.0 sdisk CLAIMED DEVICE
HP HSV200
/dev/dsk/c4t1d0 /dev/rdsk/c4t1d0

Switch is B-series domian ID 13, EVA is connected to port 4, LUN is 8( =1.0).

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
Sunny Jaisinghani
Trusted Contributor

Re: hardware address and nport id mapping

so if my HBA FC port is

0/0/12/0/0

and the nport id is 0x20200

then the domain id will be the MSB of nport id i.e. (2)

the port will be (255) for peripheral device addressing or LSB of nport id for other addressing methods.

the LUN is (0)

so here how do i find out what addressing method is used???????
Torsten.
Acclaimed Contributor

Re: hardware address and nport id mapping

do you have an ioscan output?
This is the most important source for information for hp-ux.

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
Sandman!
Honored Contributor

Re: hardware address and nport id mapping

The nport_id is a compact way of representing the Domain, Area and Port of the FC connection (in hex form). The system sends the 24 bit nport_id in each and every frame instead of sending the 64 bit WWN (more efficient). The nport_id of 0x20200 in your case evaluates to:

Domain = 0x2 = 2 (dec)
Area = 0x02 = 2 (dec)
Port = 0x00 = 0 (dec)

And the path to your FC attached disks would be...

0/0/12/0/0.2.2.0
Torsten.
Acclaimed Contributor

Re: hardware address and nport id mapping

AFAIR this is different for B-, M- and C-Series switches.

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
Sunny Jaisinghani
Trusted Contributor

Re: hardware address and nport id mapping

Torsten and Sandman

Thank you for your useful answers.

U said that nport id represents the Domain, Area and Port. i would like to add to this point that it also represents Bus, target and LUN.

How to find the above three fields??

0/0/12/0/0.2.2.?.?.?

@Torsten
i want to know how to find hardware address from nport id and not nport id from hardware address. Anyways this is the ioscan output

usxdsm02/>ioscan -fnH 0/0/12/0/0 | more
Class I H/W Path Driver S/W State H/W Type Description
===========================================================================
fc 2 0/0/12/0/0 td CLAIMED INTERFACE HP Tachyon XL2 Fi
bre Channel Mass Storage Adapter
/dev/td2
fcp 10 0/0/12/0/0.2 fcp CLAIMED INTERFACE FCP Domain
ext_bus 61 0/0/12/0/0.2.0.3.0 fcparray CLAIMED INTERFACE FCP Ar
ray Interface
target 73 0/0/12/0/0.2.0.3.0.0 tgt CLAIMED DEVICE
ctl 409 0/0/12/0/0.2.0.3.0.0.0 sctl CLAIMED DEVICE COMPAQ
HSV110 (C)COMPAQ
/dev/rscsi/c61t0d0
target 74 0/0/12/0/0.2.0.3.0.1 tgt CLAIMED DEVICE
ctl 410 0/0/12/0/0.2.0.3.0.1.0 sctl CLAIMED DEVICE COMPAQ
Torsten.
Acclaimed Contributor

Re: hardware address and nport id mapping

Again,

the interpretation of the nPort ID value may depend on the switch type. Consider there are switches with blades ... (e.g. director).


BTW, there is no disk in you ioscan ...

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
Sunny Jaisinghani
Trusted Contributor

Re: hardware address and nport id mapping

There are no disks connected. only tape drives. have a look



target 140 0/0/12/0/0.2.0.255.0.8 tgt CLAIMED DEVICE
tape 6 0/0/12/0/0.2.0.255.0.8.0 stape CLAIMED DEVICE HP Ultrium 2-SCSI
/dev/rmt/6m /dev/rmt/6mn /dev/rmt/c65t8d0BEST /dev/rmt/c65t8d0BESTn
/dev/rmt/6mb /dev/rmt/6mnb /dev/rmt/c65t8d0BESTb /dev/rmt/c65t8d0BESTnb
target 141 0/0/12/0/0.2.0.255.0.9 tgt CLAIMED DEVICE
tape 7 0/0/12/0/0.2.0.255.0.9.0 stape CLAIMED DEVICE HP Ultrium 2-SCSI
/dev/rmt/7m /dev/rmt/7mn /dev/rmt/c65t9d0BEST /dev/rmt/c65t9d0BESTn
/dev/rmt/7mb /dev/rmt/7mnb /dev/rmt/c65t9d0BESTb /dev/rmt/c65t9d0BESTnb
Torsten.
Acclaimed Contributor

Re: hardware address and nport id mapping

What do you really want to know???

The first ioscan is showing a EVA5000 - fabric attached, the second is showing tapes. The meaning of your nPort is always different, but unique in every case.
Are the tape drives in a library?


BTW, if you don't need to see the EVA from this HBA, adjust your zoning.

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
Sunny Jaisinghani
Trusted Contributor

Re: hardware address and nport id mapping

I am just trying to investigate the following EMS notification

Adapter at hardware path 0/0/12/0/0 : Unable to open previously opened
target nport ID = 0x20200

when i checked with ioscan on the above hardware address i found that all devices are claimed except a tape device. the Fiber channel mass storage adapter is ONLINE.

ext_bus 31 0/0/12/0/0.2.2.255.0 fcpdev NO_HW INTERFACE FCP Device Interface
target 147 0/0/12/0/0.2.2.255.0.0 tgt NO_HW DEVICE
tape 12 0/0/12/0/0.2.2.255.0.0.0 stape NO_HW DEVICE HP Ultrium 2-SCSI
/dev/rmt/12m /dev/rmt/12mn /dev/rmt/c31t0d0BEST /dev/rmt/c31t0d0BESTn
/dev/rmt/12mb /dev/rmt/12mnb /dev/rmt/c31t0d0BESTb /dev/rmt/c31t0d0BESTnb


the hardware address of the tape having NO_HW status is 0/0/12/0/0.2.2.255.0.0.0

now i want to know if the above hardware address represents this nport id 0x20200

i have attached the complete output of the ioscan command executed on hardware adress 0/0/12/0/0
Torsten.
Acclaimed Contributor

Re: hardware address and nport id mapping

In this case

0/0/12/0/0.2.2.255.0.0.0 has nport id 0x020200

What did you changed? I assume the drive is inside the STK 700 box, but are they direct wired to the switch? The last 2 drives are different to all others - is there something like a bridge in use?

Back to the problem.
Did you exchange the drive?
In this case it has a different WWN now and the driver won't allow the drive to login. You will see a clear message in syslog.log.

Or did you change the switch port from 2 to 3 by chance?

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
Sunny Jaisinghani
Trusted Contributor

Re: hardware address and nport id mapping

I don't have physical access to the server since it is at a remote location. NOr do i have much hardware knowledge .

So i cannot answer your questions.

i'll try to find something in syslog and get back.

Anyways thanks for clearing my doubts
Sandman!
Honored Contributor
Solution

Re: hardware address and nport id mapping

>the hardware address of the tape having NO_HW status is 0/0/12/0/0.2.2.255.0.0.0

>now i want to know if the above hardware address represents this nport id 0x20200

The above H/W address does NOT equal nport ID 0x020200 instead it equates to 0x0202FF. You can see all nport IDs visible from the HBA on path 0/0/12/0 as (and post the output here):

# fcmsutil /dev/td2 ns_query_ports

Most likely the nport ID 0x20200 is NOT in the above output and hence the error.

~cheers
Sunny Jaisinghani
Trusted Contributor

Re: hardware address and nport id mapping

this is the output of fcmsutil /dev/td2 ns_query_ports

The following is the list of nport ids:
1. 20003
2. 20004
3. 20005
4. 20007
5. 20008
6. 20009
7. 2000a
8. 2000b
9. 2000e
10. 2000f
11. 20012
12. 20013
13. 20300


U were right. the nport id does not exists.

Thanks a lot
Torsten.
Acclaimed Contributor

Re: hardware address and nport id mapping

Remember the message:

"Adapter at hardware path 0/0/12/0/0 : Unable to open previously opened
target nport ID = 0x20200"

Means at least it _WAS_ there. Now it is NO_HW.

If your posted ioscan is complete for this path, there is no device file for the last tape. Looks like somebody changed the port.

Anyway, I'm pretty sure the nPort ID is for this device connected likely to a B-series switch domain ID 2 port 2 (now 3).

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
Sandman!
Honored Contributor

Re: hardware address and nport id mapping

Slight mixup owing to VSA and PDA addressing modes. The 255 in the port field means that you are using Peripheral Device Addressing (PDA) mode as opposed to Volume Set Addressing (VSA) mode.

Also the hardware path of 0/0/12/0/0.2.2.255.0 will have nport ID of 0x20200 as it is configured for Public Loop or AL_PA Access. I had incorrectly stated earlier that the 0/0/12/0/0.2.2.255.0 hardware path will have 0x202FF nport ID.

~hope it helps
Torsten.
Acclaimed Contributor

Re: hardware address and nport id mapping

All the different addressing modes could be some confusing sometimes ...

BTW, here you an see that the nPort ID only cannot give you the hardware path - there are so many possibilities due to the topology.

IMHO, 3 possible reasons for your problem:

1) drive is dead
2) drive is replaced, but "fcmsutil /dev/td2 replace_dsk 0x20200" did not run (to allow the drive to log in.
3) drive is now connected to a different switch port

Ask the people onsite if at least 2) or 3) happened.

Hope this helps!
Regards
Torsten.

__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.

__________________________________________________
No support by private messages. Please ask the forum!

If you feel this was helpful please click the KUDOS! thumb below!   
Sandman!
Honored Contributor

Re: hardware address and nport id mapping

You can try running ioscan(1M) without any arguments in order to force the driver-to-device binding and may change the state of the tape hardware from NO_HW to CLAIMED.

# ioscan

And as Torsten has said that it is quiet likely that the replace_dsk command wasn't run after replacing the device i.e.

# fcmsutil /dev/td2 replace_dsk 0x20200

Also look for relevant messages in the /var/adm/syslog/syslog.log file. The messages in the logfile might clue you on what changed and on which path.

~cheers