
#Linux show mac address of interface mac
Returns 78:45:c4:30:16:3a (this is the hardware MAC address for wired connections NOT the wireless connection NOR the actual MAC number needed by the router - see above) OK, here we are and not real well figured out. Sooooo - is there an actual way to find the real MAC address from the Linux command line? Wlp3s0 is the wireless connection and using the ifconfig command shows the correct IP address mappedīUT neither 78:45:c4:30:16:3a nor a4:17:31:03:05:f8 is the true MAC address - my router is using MAC:: 16:49:f7:03:05:f8 to map the IP address I want correctly. None show anything like the term "hwaddr" (mentioned in net articles)Īnd below is the excerpt from the latter (minus "lo" and "vir**" entries - loopback and virtual) for a machine with wired and wireless ability:Ģ: enp4s0: mtu 1500 qdisc fq_codel state DOWN mode DEFAULT group default qlen 1000\ link/ether 78:45:c4:30:16:3a brd ff:ff:ff:ff:ff:ffģ: wlp3s0: mtu 1500 qdisc noqueue state UP mode DORMANT group default qlen 1000\ link/ether a4:17:31:03:05:f8 brd ff:ff:ff:ff:ff:ff Perhaps these work for someone else, but they sure do NOT work here.
#Linux show mac address of interface how to
You’ll probably also want to make sure you didn’t run the command in an unconnected virtual machine without a network like we did for the purposes of demonstration.There are many articles on the net on how to find the MAC address. You’ll want to check to make sure that you didn’t disable networking, loose a Wi-Fi connection by moving around or unplug an Ethernet cord. If you don’t see anything returned, then you’re probably not connected to a network.

There’s nothing else to do you can find MAC address data with a single command. You might have only a few on a laptop, while connected routers could ultimately list dozens of different connections if they’re sending packets in many different places. As soon as you’ve run it, you’ll receive the MAC hardware address for each networking device attached to the system. Once again, you won’t have to be root to run this command. You might instead want to hold down Shift+Ctrl+V, but the normal Ctrl+V keyboard shortcut won’t work. If this command is long and you’d like to copy it from this article, then remember that you’ll need to paste from the Edit menu in your terminal window. At the prompt, type ifconfig -a | grep HWaddr and then push enter. Like with almost everything on the Linux command line, there is more than one way to find MAC address data. Method 2: Find MAC Address with the ifconfig Command This one single command is enough to find the answer to your question without any further playing around. There really isn’t anything to do, though. You don’t want to share your MAC address with people! For security reasons, our screenshots were taken in a virtual machine, so we only had this adapter. You’ll also find link/loopback more than likely, which will consist of all zeros. You’ll quite possibly see more than one of these references if you’re on a beefier modern desktop computer or a laptop that you’ve personally upgraded.

A reference to link/ether would point to your Ethernet connection. For instance, you might see wls1:, which probably indicates a Wi-Fi connection that you’re working with. You’ll be given a list of MAC address figures and you simply need to look for the name that GNU/Linux gives to your network adapter. Method 1: Find MAC Address Numbers with ip linkĪt the prompt, simply type ip link and push enter.

You can work from whatever prompt you’re given. Those using Xfce4 can find it on the Whisker Menu in System Tools, and LXDE, KDE and GNOME Shell users should find it on the menu in the same place. Ubuntu Unity users can search for the word terminal on the Dash.

Graphical desktop environment users can usually hold down Ctrl+Alt+T to open up a terminal. You’ll need to be working on a command line interface to find MAC address information, but you won’t need to be logged in as root. Users with multiple networking interfaces will end up with more than one address to take a look at. Each computer network interface receives a unique Media Access Control (MAC) address, which explains what device it belongs to. If you need to find MAC address numbers for any network interface attached to your computer, then Linux makes this quite easy.
