I have set up a few soon-to-be production VMs running on QEMU-KVM on Ubuntu 10.04 LTS.

As for networking, I chose the "NAT" option in Virt-Manager and each VM now gets an IP address 192.168.122.x from QEMU's internal DHCP server.

I've restarted the VMs several times and the IP addresses are always the same. I've given each VM a network adapter with a unique MAC address.

So can I rely on that QEMU's internal DHCP server will give out the same IP addresses? Or is the safest option to set static IP addresses from within each VM?

1 Answer 1


Seems my question is answered in the libvirt manual. One needs to specifically ensure that the same IP is handed out via DHCP each time. Here's how this can be specified:

  <ip address="" netmask="">
      <range start="" end="">
      <host mac="01:23:45:67:89:ab" name="foo.example.com" ip="">

Alternatively, static IP is a viable option.


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .