Archive for June, 2011

Change Network Card MAC in Ubuntu/Linux

A Media Access Control address (MAC address) is a unique identifier assigned to network interfaces for communications on the physical network segment. Read more about MAC addresses here.

Tip: Please write down your current MAC address before you continue

To change the MAC address in Ubuntu, perform the following:

Temporary solution

  1. Open terminal and check your current MAC address:
    ifconfig |grep HWaddr  

    Output should be something like this (MAC’s are red):
    eth0           Link encap:Ethernet  HWaddr f4:6d:0b:37:f9:83
    vboxnet0  Link encap:Ethernet  HWaddr 0b:00:23:00:00:00
    wlan0       Link encap:Ethernet  HWaddr e0:c9:d5:1a:ed:b5

  2. Now, disable the network interface (eth0 for the wired network connection, wlan0 for wireless etc.):
    sudo ifconfig eth0 down


  3. Change the MAC address:
    sudo ifconfig eth0 hw ether 00:15:a5:d5:39:19

  4. Enable the network interface:
    sudo ifconfig eth0 up

  5. Check if the change is successful:
    ifconfig |grep HWaddr  

    Should return the changed address:
    eth0           Link encap:Ethernet  HWaddr 00:15:a5:d5:39:19
    vboxnet0  Link encap:Ethernet  HWaddr 0b:00:23:00:00:00
    wlan0       Link encap:Ethernet  HWaddr e0:c9:d5:1a:ed:b5

Permanent solution

  1. Open the interfaces file, you can choose any text editor you want:
    sudo vi /etc/network/interfaces  

    You should see something like the following:
    auto lo
    iface lo inet loopback

  2. Add this line at the bottom of the file:
    hwaddress ether 00:15:a5:d5:39:19 

    The red text is the MAC address, so replace this one with your desired address.

  3. Restart the networking service or your computer:
    sudo /etc/init.d/networking restart

Common issue(es)

  1. If there is no connectivity after ifconfig eth0 up or sudo /etc/init.d/networking restart try the following:
    dhclient eth0 

    This will request a new IP address and it should fix the connectivity issue.

Add Windows XP apps in Windows XP Mode in Windows 7

Recently I needed to add applications in Windows 7 which are only compatible with Windows XP. I discovered the Virtual PC in Windows 7 and the Windows XP Mode. It is great concept and it works quite nice because you don’t notice any difference to the applications (except some RAM usage), but there is a little problem for non-installable applications. They do not show in the Windows XP Mode menu automatically.

I noticed that only some applications are listed in the Windows XP Mode list and the one that I needed was not available there. You are able to add any application in that list by performing the following:

  1. Start Windows XP Mode in Desktop mode
  2. Create a shortcut of your application’s main executable file (.exe)
  3. Move the shortcut file (.lnk) in the following path: C:\Documents and Settings\All Users\Start Menu\Programs folder

The application should be now available in the Start Menu under Windows XP Mode.

Firefox: How to save tabs on exit and display them on restart

With Firefox 4 (and 5) the feature which asks if you want to save the tabs on exit/close is no longer active by default. This feature was great for me because I restart Firefox from time to time to refresh my RAM or just restart the machine and I don’t want to add everything in bookmarks or lose some tabs that I am intending to read/view later.


1. Open the about:config page by typing that in the Firefox’s address bar, then press Enter

About-config in the address bar

2. Agree to the warning screen by clicking the I’ll be careful, I promise! button

3. Locate the preference browser.showQuitWarning (type it or part of it in the filter on the top), if its value is false, double click on it and the value will change to true.

4. Repeat step 3 for the following preferences:

  • browser.warnOnQuit
  • browser.warnOnRestart
  • browser.tabs.warnOnClose

Now every time you close or restart Firefox it will warn you and ask if you want to save the tabs or not. You can modify these settings to your needs, by following the above steps (double click will set the values to false).

This is tested on Firefox 4.x and Firefox 5.x.

What is this ‘redo’ thing?

Recently I replaced my computers at work and at home. This resulted in a vast amount of data transfer between computers, many passwords to transfer, settings, software installations etc. I found myself in the same problem as I did when I first encountered the issues, which is googling around, trying different configurations, installing different software etc.

Now, my intentions are to write those things down here so that next time I need them (and I am sure I will need most of ’em) I will have them handy and be able to perform them in no time. This is also written as a blog and not a local file on my machine, so that others who encounter the same or similar problems will be able to solve them in no time and have more time to surf 🙂 .

Go to Top