Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

While looking to find the MAC Address of my computer as it appears to a wireless network, it was recommended that I run ifconfig.

Having executed that command in the Terminal, I noticed that, unlike my other machine, the connected network seemed to be listed as an Ethernet, even though the built in wireless card is the thing I am currently using to post this.

ifconfig output:

lewisgoddard@t42:~$ ifconfig
eth0      Link encap:Ethernet  HWaddr 00:0d:60:7b:d2:18  
          UP BROADCAST MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

eth1      Link encap:Ethernet  HWaddr 00:0c:f1:53:55:c5  
          inet addr:192.168.1.10  Bcast:192.168.1.255  Mask:255.255.255.0
          inet6 addr: fe80::20c:f1ff:fe53:55c5/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:716 errors:1 dropped:1 overruns:0 frame:0
          TX packets:710 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:620786 (620.7 KB)  TX bytes:80480 (80.4 KB)
          Interrupt:11 Base address:0xe000 Memory:c0210000-c0210fff 

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:182 errors:0 dropped:0 overruns:0 frame:0
          TX packets:182 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:19665 (19.6 KB)  TX bytes:19665 (19.6 KB)

Is it possible that Ubuntu is confused somehow?

If not, am I misinterpreting my results, and my MAC Address may not be 00:0c:f1:53:55:c5 ?

share|improve this question
1  
I'm not an expert, but if you're using a wireless connection to write this post, it's mac address is 00:0c:f1:53:55:c5, since it has an IP number, it's the connection you're actually using. –  Evandro Silva Oct 20 '12 at 21:07

5 Answers 5

up vote 3 down vote accepted

I am not exactly sure why this happens, but I have seen it before too.

You are right about the MAC address -- it's the one in eth1.

share|improve this answer
2  
AGREE. If the computer has an Ethernet port, of the ability to add one, that will have its own MAC address. So, also having a "built in wireless card" will mean an additional MAC address. –  david6 Oct 20 '12 at 23:38

Use ip instead of the outdated ifconfig. Example:

ip addr show

...
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000
    link/ether 04:7d:4b:28:51:33 brd ff:ff:ff:ff:ff:ff
...

FINDING: The MAC address of network interface/adapter eth0 is 04:7d:4b:28:51:33.

share|improve this answer

iwconfig shows the wireless information including the mac address, just like ifconfig shows the ethernet information. Here is a link for iwconfig that tells what everything it shows and what the information means. iwconfig

share|improve this answer

Your computer's MAC address is really only a MAC address associated with an interface, whether it is physical or virtual. Things get confusing when there is bridging or tunneling interfaces, vm interfaces, bonded interfaces, and so on. With this output, I'm not sure why your interface is listed as eth1, but given that it is the only one with an address, that's probably it.

Without more info, I'm guessing that Ubuntu/Linux is misidentifying your onboard NIC.

You can use wireshark or tcpdump to confirm that traffic is originating from the interface you believe it is.
wireshark is a GUI-based capture tool (with a command-line option), while tcpdump is a command line tool. You can see its output quickly (once installed) with something like sudo tcpdump -i any.

If you have access to your wireless gateway, you can use it to view the connected devices. The MAC address your system is using to connect will be there.

As LivewireBT suggests, there may be a clue in /etc/udev/rules.d/70-persistent-net.rules .

To see what interfaces your computer is recognizing and bringing up, look at the output of your system logs. Using dmesg is probably the easiest.

Here's an example:

~$ dmesg | egrep 'lan|eth'
[    1.608941] e1000e 0000:00:ff.0: eth0: (PCI Express:2.5GT/s:Width x1) 5c:af:0a:15:42:a2
[    1.608943] e1000e 0000:00:ff.0: eth0: Intel(R) PRO/1000 Network Connection
[    1.608994] e1000e 0000:00:ff.0: eth0: MAC: 9, PHY: 10, PBA No: 2041FF-0FF
[   29.486325] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
[   30.532255] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
[   33.622226] e1000e: eth0 NIC Link is Up 1000 Mbps Full Duplex, Flow Control: Rx
[   33.622856] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
[   43.880499] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
[   43.880939] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
[   50.500518] wlan0: authenticate with 0c:d9:0f:23:ae:0f
[   50.541272] wlan0: send auth to 0c:d9:0f:23:ae:0f (try 1/3)

Note the MAC addresses associated with e1000e/eth0 (the wired Gigabit interface), and wlan0 (the wireless). Your computer should have something similar, even if the actual interface name is not what we'd expect.

share|improve this answer

Removing the entry from /etc/udev/rules.d/70-persistent-net.rules might help assigning the interface a more suitable name.

share|improve this answer

Your Answer

 
discard

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.