:: Re: [DNG] Purpose of an OS: was net…
Page principale
Supprimer ce message
Répondre à ce message
Auteur: Simon Hobson
Date:  
À: dng@lists.dyne.org
Sujet: Re: [DNG] Purpose of an OS: was network device naming
Didier Kryn <kryn@???> wrote:

> Out of curiosity, why are the virtual Ethernet given random addresses?


Well they have to have something !
For Xen, they've registered an OUI to get a block of MAC addresses to use. If you don't specify teh MAC address in the VM config then it'll pick one at random, but you can specify a specific address (that's what I do - derived from the IP address) and that will be used. If you specify an address then the machine will behave as though it has a fixed address - but obviously you have to manage the assignment of addresses and ensure uniqueness within your own network.

"Interesting" things happen if you get this wrong and start two VMs with the same MAC address :-(


I suppose the alternative would be for the virtualisation manager to keep some state - assign random addresses to new VMs, but then store those assignments to make them sticky - only changing them if something else (eg a VM hosted on another host) has taken the same one.

Windows HyperV is the same. VMs change MAC addresses every time they are restarted - the difference is that my colleagues can't be bothered setting fixed ones. I know this as I have Nagios setup to monitor the network for rogue devices (or duplicated IP addresses) - and I have to update it's config every time one of the Windows VMs is restarted.