ethX Issues with Xen and Ubuntu

My new guest VMs under Xen seem to be having issues where upon each reboot, the network interface gets incremented by 1. For instance, it starts at eth0, then goes to eth1, then eth2, and eventually ethX. There are two issues to fix: 1) get the count back to 0, and 2) stop it from counting again.

I was able to get them to decrease by looking in the /etc/udev/rules.d/70-persistent-net.rules file and removing all entries.

Next, I was able to prevent this by simply inserting a MAC address to the interface in the configuration. For instance, one of my domU’s has this entry:

vif         = [ 'mac=00:D0:59:83:DC:B5,bridge=xenbr0' ]

Lastly, I made sure (as I would with any server) to create an entry in the /etc/network/interfaces file.

auto eth0
iface eth0 inet static
address 192.168.1.16
gateway 192.168.1.1
netmask 255.255.255.0

Works like a charm.

Last Xenful Comments

One of the biggest things I regret is not utilizing Xen more. I’ve finally been admitted to Amazon’s EC2 Limited Beta, just two days before I leave, so not enough time to actually do anything fun. However, I think Xen is an ideal infrastructure aid for SMEs in particular. The cost of technology is continuing to decrease, which means bigger servers cost less. This is great for the small/branch office. Let me explain.

One of the themes I noticed while studying and taking the MCSE was that the solution to the majority of the problems was to just buy more servers. Even for simple things like DHCP, buy another server. I’ve always operated on a limited budget, and anyways, I don’t think money should be wasted on resources when it isn’t needed. With a VT chipset, you aren’t tied to any OS in particular.

My friend Ian and I were talking and he illustrated a great usage of Xen through his work. What he’s ended up doing is installing the Small Business Edition of Server 2003 in a Xen node. The reasoning is that SBE is, apparently extremely difficult to create backups of – mainly due to odd file locking behavior. I’ve had similar thoughts, but mainly taking advantage of Xen’s migration feature. The idea of taking a small branch office and putting everything on a Xen server is quite appealing to me, especially considering a second server could be used to create virtual hot spare.

As you can see, I like Xen. I’ve found it relatively easy to install, and the fact that it is starting to come bundled with recent distributions is pretty darn, sweet.