Tips

How to find MAC address on Linux?

Posted on

If you need to find MAC address numbers for any network interface attached to your computer, then Linux makes this quite easy. Each computer network interface receives a unique Media Access Control (MAC) address, which explains what device it belongs to.

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. Graphical desktop environment users can usually hold down Ctrl+Alt+T to open up a terminal. Ubuntu Unity users can search for the word terminal on the Dash.

Method 1: Find MAC Address Numbers with IP link

  • At the prompt, simply type the IP link and push enter. 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. For instance, you might see wls1:, which probably indicates a Wi-Fi connection that you’re working with. A reference to link/ether would point to your Ethernet connection.
  • You’ll also find link/loopback more than likely, which will consist of all zeros. This just points back to your own host. For security reasons, our screenshots were taken in a virtual machine, so we only had this adapter.

Method 2: Find MAC Address with the ifconfig Command

  • Like with almost everything on the Linux command line, there is more than one way to find MAC address data. At the prompt, type ifconfig -a | grep HWaddr and then push enter. If this command is long and you’d like to copy it from this article, then remember that you’ll need to paste it from the Edit menu in your terminal window. You might instead want to hold down Shift+Ctrl+V, but the normal Ctrl+V keyboard shortcut won’t work.
  • Once again, you won’t have to be root to run this command. As soon as you’ve run it, you’ll receive the MAC hardware address for each networking device attached to the system. 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.

Join Tip3X on Telegram 


Click to comment

Most Popular

Exit mobile version