In contrast to IP addresses, MAC addresses do not change. It was a one-of-a-kind identifier given to each device by the manufacturer. To transfer data between devices on a local area network, a MAC address is used instead of each device’s unique Internet Protocol (IP) address. The Source MAC Address and the Destination MAC Address are included in every network packet.
Also Read: How to Zip a Folder in Linux In Few Easy Steps!
To what end would one alter their Mac address?
A media access control (MAC) address is a special number that identifies a device on a network. Changing the Mac address will aid in maintaining online anonymity. When you use the MAC address of another device on the network, you are able to avoid being blocked.
Steps to Changing Your Linux Machine’s MAC Address 1. Launch Terminal and enter the ifconfig -a command to see what network adapters your computer has.
To modify the MAC address of a specific network interface, click “Change MAC Address.”
Third, we must shut down the network interface in order to modify its MAC address.
ifconfig wlan0 down
MAC Address Modification (Replace XX:XX:XX:XX:XX:XX with the mac address that you want to set)
Entering “ifconfig wlan0 hw ether” XX:XX:XX:XX:XX:XX
Five, raise the network interface
To bring up wireless network interface wlan0, type ifconfig wlan0 up 6. So long. It looks like your MAC address has been temporarily updated.
Also Read: A Complete Guide How to Fix Connection Refused Error in Linux Easily!
In Linux, where can I find my MAC address and modify it?
You can see both the wired ethernet card (enp2s0) and the wireless wlp3s0 card (above). The MAC addresses look like XX:XX:XX:XX:XX:XX, which is 12 digits long and divided into 6 fields of 2 characters each, with the letters being separated by colons “:”. The Media Access Control (MAC) address of the ethernet card is d0:17:c2:12:3c:cd, while that of the wireless network adapter, wlp3s0, is a2:58:a6:6a:29:04.
In my case, d0:17:c2 indicates that my device was made by ASUS, the first manufacturer listed in the first set of numbers and letters. The final 12 digits represent a unique hardware identification number.
While the network card is active, the MAC address cannot be changed. As a result, alter the MAC address before you have to physically remove the network card. Here’s an example of how to do it with the ip command; just swap out “Device” for the name of your network gadget.
Also Read: How to Fix App Keeps Stopping in Android Studio?
Here’s the command you’ll need to execute in order to give your device a new MAC address: Be sure to replace Device> with the name of your network gadget and New MAC address> with the desired address.
When you’re done, restart your network card by running the following command, where Device> should be your network card’s actual name.
A successful MAC address change from the previous display (d0:17:c2:12:3c:cd) to the current display (00:00:00:00:00:01) is shown in the following screenshot.
The problem with the manual method is that it will not stay changed after a reboot.