Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

How can I get the MAC address for the wireless access point in Ubuntu?

share|improve this question

migrated from stackoverflow.com Jan 22 '11 at 23:46

This question came from our site for professional and enthusiast programmers.

2  
Not programming... –  leppie Jan 22 '11 at 18:43
    
@leppie: it could be a programming question, if the asker would say, instead, "in bash, how do I..." –  David Jan 22 '11 at 18:56
    
@MAMProgr: Do you want to know how to do this in bash, or using the GUI? If you want to use the GUI to do this, this question should be asked on su. –  David Jan 22 '11 at 18:57
    
@David: The fact that it is tagged with ubuntu and not some programming platform or language pretty much excludes that hypothesis. –  leppie Jan 22 '11 at 19:57
    
@leppie: doesn't the bash shell come with ubuntu? Until the asker gives more information, I don't think there's much of a onclusion that could be drawn. –  David Jan 22 '11 at 20:04
show 3 more comments

3 Answers

Either connect to the point, and do

iwconfig | grep "Access Point"

or find your access point in the output of

iwlist wlan0 scan

(if you have wireless interface called not wlan0, substitute appropriately).

share|improve this answer
    
Wonderful. Both commands show the access point MAC address. –  so_mv Mar 1 '13 at 8:20
add comment

Use the arping utility with your AP's IP as an argument:

$ arping 192.168.0.1
ARPING 192.168.0.1 from 192.168.0.200 eth0
Unicast reply from 192.168.0.1 [00:48:6C:38:B7:4D]  0.660ms
Unicast reply from 192.168.0.1 [00:48:6C:38:B7:4D]  0.590ms
Unicast reply from 192.168.0.1 [00:48:6C:38:B7:4D]  0.610ms
Unicast reply from 192.168.0.1 [00:48:6C:38:B7:4D]  0.410ms
Sent 4 probes (1 broadcast(s))
Received 4 response(s)

You can see the MAC address in the reply.

share|improve this answer
add comment

You may try dmesg when connecting/connected to wireless access point:

$ dmesg | grep "probe to"

On my box (Fedora 14), I get line like this:

[ 5257.283188] wlan0: direct probe to 00:23:eb:3a:99:e0 (try 1)

Not sure whether under different kernel or other configuration on other distro like ubuntu has the same info printed out. Please try.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.