This article explains how to find MAC address of the PC in Linux, Windows, FreeBSP, NetBSP, OpenBSD, Caldera/SCO, IRIX, HP-UX, NeXTStep, AIX, Tru64 UNIX etc.Typically each Ethernet adapter in the world is programmed with an unique MAC address by the manufacturer. In other words, no two Ethernet adapters will have same MAC address.

In Linux (Fedora/Ubuntu/Other flavours)

[neo@techpulp ~]# ifconfig eth0
eth0      Link encap:Ethernet  HWaddr 00:A3:B2:01:5E:4B
inet addr:192.168.1.2  Bcast:192.168.1.255  Mask:255.255.255.0
...

If you have more than one Ethernet adapters in the system, you can use “ifconfig -a” command.

In Microsoft Windows NT/2000/2003/XP
Open Run Command Window by pressing R while holding Windows Start Key. Otherwise Click on “Run …” in the start menu to open “Run command” window.

Type “cmd” in the text box and press ENTER key. It will open Windows Command Prompt. Run “ipconfig /all” command.

c:\> ipconfig /all

....
Ethernet adapter Wired:
Connection-specific DNS Suffix  . : techpulp.com
Description . . . . . . . . . . . : Intel Ethernet Express (e1000)
Physical Address. . . . . . . . . : 00-A3-B2-01-5E-4B

In Windows 95/98/ME

1. Click Start Menu and Click on “Run..”. It opens Windows Command Prompt.

2. Run command “winipcfg” at the command prompt. It opens a window.

c:\> winipcfg

3. Select appropriate Ethernet adapter.

4. Your adapter’s MAC address is located next to “Physical Address“.

In Macintosh OS X

1. From the dock, select “System Preferences“.

2. Select “Network” > “Location” > “Interface”

Wired (MacOS 10.2 and earlier)

3. Select “TCP/IP” tab and the number next to “Ethernet Address” is the MAC address.


Wired (MacOS 10.3 and later)

3. Select “Ethernet” tab and the number next to “Ethernet ID” is the MAC address.

Wireless (AirPort)

3. Select “AirPort” tab and the number next to “AirPort ID” is the MAC address.

In NetBSD or FreeBSD

[neo@techpulp ~]# ifconfig -a
  ed0: flags=8843 mtu 1500
         inet 192.168.1.2 netmask 0xffffff00 broadcast 192.168.1.255
         ether 00:A3:B2:01:5E:4B

In OpenBSD

[neo@techpulp ~]# netstat -in
Name  Mtu  Network  Address           Ipkts    Ierrs Opkts   Oerrs Colls
fxp0  1500 <Link>   00:a3:b2:01:5e:4b 1042  0     7251  0     0

In Sun Solaris OS

[neo@techpulp ~]# ifconfig -a
le0: flags=863 mtu 1500
     inet 192.168.1.2 netmask ffffff00 broadcast 192.168.1.255
     ether 0:a3:b2:1:5e:4b

Sun Solaris removes leading zeros while displaying MAC address. In the above example, it displays MAC address as “0:a3:b2:1:5e:4b” instead of “00:a3:b2:01:5e:4b”.

In SGI UNIX or IRIX

[neo@techpulp ~]# netstat -ia
Name  Mtu    Network   Address            Ipkts   Ierrs   Opkts  Oerrs  Coll
ec0   1500   nowhere   warum              76183 0  98362     0  0
                       192.168.1.2
                       00:a3:b2:01:5e:4b

Alternately, you can also use following command.

[neo@techpulp ~]# /etc/nvram eaddr

In HP-UX

[neo@techpulp ~]# lanscan
Hardware Station        Dev Hardware Net-Interface   NM  Encapsulation      Mjr
Path     Address        lu  State    NameUnit State  ID  Methods            Num
2.0.2    0x00A3B2015E4B 0   UP       lan0     UP     4   ETHER              52

This operating system displays entire MAC address as a hexa-decimal integer. It displays MAC address as “0x00A3B2015E4B” instead of “00:A3:B2:01:5E:4B”.

In Sco UnixWare or Open UNIX or Caldera

[neo@techpulp ~]# ndstat
   Device       MAC address in use    Factory MAC Address
   ------       ------------------    -------------------
   /dev/net0    00:a3:b2:01:5e:4b     00:a3:b2:01:5e:4b

In IBM UNIX or AIX

[neo@techpulp ~]# netstat -ia
Name  Mtu    Network   Address            Ipkts   Ierrs   Opkts  Oerrs  Coll
ec0   1500   nowhere   flotsam            34512   0       54232   0     0
                       192.168.1.2
                       00:a3:b2:01:5e:4b

In Digital UNIX or Tru64 UNIX

[neo@techpulp ~]# netstat -ia
Name  Mtu    Network   Address            Ipkts   Ierrs   Opkts  Oerrs  Coll
ec0   1500   nowhere   jetsam             65233   0       92629  0      0
                       192.168.1.2
                       00:a3:b2:01:5e:4b

In NeXTStep

[neo@techpulp ~]# ifconfig -a
le0: flags=863 mtu 1500
     inet 192.168.1.2 netmask ffffff00 broadcast 192.168.1.255
     ether 0:a3:b2:1:5e:4b

Similar to Sun Solaris, this operating system also removes leading zeros from the MAC address while displaying.