Difference between revisions of "Libvirtd and dnsmasq"

From Libvirt Wiki
Jump to: navigation, search
(Running your own dnsmasq with libvirtd)
(Running your own dnsmasq with libvirtd)
Line 9: Line 9:
 
<i>Either:</i>
 
<i>Either:</i>
  
  listen-address=eth0
+
  interface=eth0
  
 
<i>or:</i>
 
<i>or:</i>
  
  listen-address=127.0.0.1
+
  listen-address=192.168.0.1
  
(Replace listen-address with the interface(s) or address(es) you want your global dnsmasq to answer queries on).
+
(Replace interface or listen-address with the interface(s) or address(es) you want your global dnsmasq to answer queries on).
  
 
<i>And</i> uncomment this line to tell dnsmasq to only bind specific interfaces, not try to bind all interfaces:
 
<i>And</i> uncomment this line to tell dnsmasq to only bind specific interfaces, not try to bind all interfaces:
  
 
  bind-interfaces
 
  bind-interfaces

Revision as of 19:20, 17 February 2010

Running your own dnsmasq with libvirtd

libvirtd runs its own private dnsmasq instance to service the default network.

If you are running your own "global" dnsmasq, then this can cause your own dnsmasq to fail to start (or for libvirtd to fail to start its dnsmasq and the default network). This happens because both instances of dnsmasq might try to bind to the same port number on the same network interfaces.

You have to change the global /etc/dnsmasq.conf as follows:

Either:

interface=eth0

or:

listen-address=192.168.0.1

(Replace interface or listen-address with the interface(s) or address(es) you want your global dnsmasq to answer queries on).

And uncomment this line to tell dnsmasq to only bind specific interfaces, not try to bind all interfaces:

bind-interfaces