Changing Ethernet MAC address in Ubuntu 11.04

This is just a quick command line hack to restart your computer’s wired ethernet interface with a different MAC address (i.e. hardware address). This works on my Asus EeePC 901 in Ubuntu 11.04. In a terminal, do the following:

ifconfig eth0 down
ifconfig eth0 hw ether 00:12:18:3e:42:4c
ifconfig eth0 up

The above three commands stop the interface, change the MAC address, and restart the interface. Obviously, you need to change the address in the middle command to whatever one you want to use. I’ve changed the one in the example above to a random address.

To check that the hardware address has changed, just run the following command:

ifconfig eth0

The current hardware address should be listed along with several lines of other information. When the computer is restarted, the MAC address should have returned to its normal value (i.e. the network interface’s actual hardware address).

This entry was posted in Uncategorized and tagged , , , , , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s