How to change MAC address in Linux

First find the physical MAC address of your machine by running the following command :

$ ifconfig -a | grep HWaddr
eth0 Link encap:Ethernet HWaddr 00:80:48:BA:d1:2


The hexadecimal numbers in blue denote my machine's MAC address. Yours will be different. Learn how to use the ifconfig Linux command.

Next, login as root in Linux and enter the following commands -

# ifconfig eth0 down
# ifconfig eth0 hw ether 00:80:48:BA:d1:30
# ifconfig eth0 up
# ifconfig eth0 |grep HWaddr


Note above that I have changed the MAC address to a different number highlighted in blue. 00:80:48:BA:d1:30 is the new MAC address I have provided for my Linux machine. You can choose any 48 bits hexadecimal address as your MAC address.

  • 113 Users Found This Useful
Was this answer helpful?

Related Articles

FFMPEG

*MPlayer (MPlayer-1.0rc1.tar.bz2) *Codecs (essential-20061022.tar.bz2) *Flvtool...

How do I change my Webmin password if I can't login?

Included with the Webmin distribution is a program called changepass.pl to solve erecisely this...

How to Install Wget

Ever logged into your server via ssh and needed to download a file, then wget is what you...

How to install Zend for Linux

1. Download Zend in the server you want to install. Linux 32b -...

Debian Lenny Apt-get List

In order to use the officials debian sources paste this into your sources.list #nano...