天天看點

Solaris 10 檢視機器的網卡mac位址

方法1:

    以root運作/usr/sbin/ifconfig -a 

----------------------------------------------------------------------------------

# ifconfig -a

lo0: flags=2001000849<UP,LOOPBACK,RUNNING,MULTICAST,IPv4,VIRTUAL> mtu 8232 index 1

        inet 127.0.0.1 netmask ff000000 

lo0:1: flags=2001000849<UP,LOOPBACK,RUNNING,MULTICAST,IPv4,VIRTUAL> mtu 8232 index 1

        zone udi

elxl0: flags=1000843<UP,BROADCAST,RUNNING,MULTICAST,IPv4> mtu 1500 index 2

        inet 192.168.11.5 netmask fffff000 broadcast 192.168.15.255

        ether 0:1:2:c5:33:e2 

方法2:

    /usr/sbin/arp -a  (普通使用者可以運作)

-bash-3.00$ arp -a | grep `hostname` | awk '{print $5}'

00:01:02:c5:33:e2

方法3:

/bin/netstat (普通使用者可以運作)

-bash-3.00$ netstat -p | grep `hostname` | awk '{print $5}'

本文轉自leipei部落格園部落格,原文連結:http://www.cnblogs.com/leipei2352/archive/2011/06/15/2081541.html,如需轉載請自行聯系原作者