Friday 19 May 2017

HOWTO determine the MAC address of a network interface

Introduction

Sometimes it can be useful to know the physical address of a network interface (MAC address), to perform some configuration and/or troubleshooting.

Find the MAC address

On the most of the systems this information can be retrieved using the ifconfig or the netstat commands but this is not true for IBM AIX.

To get the MAC address, use the lscfg as root as follow:

Command: displaying the MAC address of the interface <INTERFACE>

# lscfg -vpl <INTERFACE>

Example


To retrieve the MAC address of the interface ent0:

Command: displaying the MAC address of the interface ent0

# lscfg -vl ent0
  ent0             U787B.001.DNW7722-P1-T9  2-Port 10/100/1000 Base-TX PCI-X Adapter (14108902)
      2-Port 10/100/1000 Base-TX PCI-X Adapter:
        Network Address.............000D604DFA2A
        ROM Level.(alterable).......DV0210
        Hardware Location Code......U787B.001.DNW7722-P1-T9
  PLATFORM SPECIFIC
  Name:  ethernet
    Node:  ethernet@1
    Device Type:  network
    Physical Location: U787B.001.DNW7722-P1-T9

No comments:

Post a Comment