4

Usually I would be able to change my wifi mac address with the ifconfig command like :

ifconfig <iface> hw ether XX:XX:XX:XX:XX:XX

Ubuntu have however deprecated ifconfig in behalf of the "ip" command, so I was wondering if there is an way to get similar functionality using that command?

5

First run:

ip link show

This will list your network devices. Find the one you want to change. Next, run:

sudo ip link set dev <your device here> down

Then:

sudo ip link set dev <your device here> address <your new mac address>

Finally:

sudo ip link set dev <your device here> up
  • ip -c a is really handy as a first command, or just ip a which stands for ip address and gives you a slightly different display including IPv4 and IPv6 addresses. – pbhj Jun 8 at 10:17
-1

To change the MAC (Media Access Control) address of an eth0 network interface, use the following command with argument “hw ether“. For example, see below.

[root@tecmint ~]# ifconfig eth0 hw ether AA:BB:CC:DD:EE:FF

use this article, i hope this very helpfull for you!

  • 3
    The question was explicitely about an alternative to ifconfig because Ubuntu has switched to the ip command. – PerlDuck Aug 16 '18 at 14:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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