Operating System - HP-UX
1826882 Members
2834 Online
109705 Solutions
New Discussion

How to get MAC Address for Network Card in HP-UX

 
SOLVED
Go to solution
John Ferro
Regular Advisor

How to get MAC Address for Network Card in HP-UX

I am beginer to HP-UX, I would like to get MAC Address for every Network card in my server. (LAN & FC).

Regards,
Faisal m.
9 REPLIES 9
Robert-Jan Goossens
Honored Contributor

Re: How to get MAC Address for Network Card in HP-UX

Hi Faisal,

Try this command.

# lanscan

Robert-Jan
Senthil Prabu.S_1
Trusted Contributor

Re: How to get MAC Address for Network Card in HP-UX

Hi,
Lanscan command should help you

HTH,
Prabu.S
One man's "magic" is another man's engineering. "Supernatural" is a null word.
Berd
Trusted Contributor

Re: How to get MAC Address for Network Card in HP-UX

Use lanscan and look at the station address column.

This is your MAC address.

Regards,
Berd
Indrajit_1
Valued Contributor
Solution

Re: How to get MAC Address for Network Card in HP-UX

Hi;

#lanscan

You can also get the MAC address from "lanadmin" command

#lanadmin

follow the instruction as display in screen.

Cheers;
Indrajit Roy
Never Ever Give Up
rick jones
Honored Contributor

Re: How to get MAC Address for Network Card in HP-UX

As already discussed, for something you are scripting, lanscan/lanadmin are probably the way to go.

If you want something programatic, you need to make suitable DLPI calls, which should be documented in the DLPI programming manual(s) online at http://docs.hp.com/
there is no rest for the wicked yet the virtuous have no pillows
Sunny Jaisinghani
Trusted Contributor

Re: How to get MAC Address for Network Card in HP-UX

hi,

lanscan will help you get the MAC address for all NICs.

However arp will give you the primary MAC address. the Address mapped to your ip address.
Asif Sharif
Honored Contributor

Re: How to get MAC Address for Network Card in HP-UX

Assalam-O-Alaaikum,

# lanscan
Hardware Station Crd Hdw Net-Interface NM MAC HP-DLPI DLPI
Path Address In# State NamePPA ID Type Support Mjr#
10/4/16 0x080009D41DBB 1 UP lan1 snap1 1 ETHER Yes 119

The second field of the output under the Station Address column heading is the MAC address of installed network adapters. It starts with 0x showing that it is a hexadecimal number.

Regards,
Asif Sharif
Regards,
Asif Sharif
Jollyjet
Valued Contributor

Re: How to get MAC Address for Network Card in HP-UX

Hi,

There are two way's to find the mac address.

1, lanscan

2, /opt/ignite/bin/print_manifest


print_manifest will give you all the details.
Raj D.
Honored Contributor

Re: How to get MAC Address for Network Card in HP-UX

Faisal,

1. Easy way :
# lanscan ,

2. /opt/ignite/bin/print_manifest

3. sam -->Networking --> Networ Interface card

4. Look physically in the card , many times the card comes with the MAC address printed on it.


Cheers,
Raj.
" If u think u can , If u think u cannot , - You are always Right . "