No network card eth0 after changing motherboard in gentoo

I have been meaning to start a blog for too long now, but it seems I have always been waiting for the perfect article/blog. Well today I decided to start by putting some of the problems and of course solutions of stuff I meet daily at work and work it out from there.


I recently and due to an unfortunate accident had to replace the motherboard of my laptop. Since I was and remain a faithful Gentoo user. Once I brought my laptop back from repair I fired up my machine and started linux only to find a very strange thing, my Ethernet card is not detected (although the 2 motherboards are identical). I tried to start it manually by running /etc/init.d/net.eth0 start only to get:

* Starting eth0 
*   Bringing up eth0 
*     dhcp 
*       network interface eth0 does not exist 
*       Please verify hardware or kernel module (driver) 


So after googling around I found out that udev generates a rule called /etc/udev/rules.d/70-persistent-net.rules in which it maps a hardware address to a logical interface name such as eth0 and since my card mac address has changed it could no longer properly handle the device. So it turned out that deleting the file will force udev to regenerate the file and I got my Ethernet card working again.

I am sure its not a common scenario that people change their motherboard, but thought of writing this to this one person whom will be saved hours of searching by finding this blog and may be have more time to enjoy christmas with family :)


Merry Christmas :)