Comment 6 for bug 713071

Revision history for this message
In , Brian (brian-redhat-bugs) wrote :

Description of problem:
If one configures more than one network to use DHCP, multiple dnsmasq processes are started, one for each network. The problem is that each process has --dhcp-lease-max configured for the number of leases in it's own network. But since multiple dnsmasq processes share the standard lease file it's possible that more leases are already in the lease file than the newly configured network yielding an error when the new dnsmasq tries to start:

dnsmasq: too many stored leases

Version-Release number of selected component (if applicable):
0.8.5

How reproducible:
100%

Steps to Reproduce:
1. define a /24 network in libvirt
2. obtain (or simulate by populating the leases file) 30 leases
3. define a second /28 network

Actual results:
libvirtd will report:

09:46:47.004: error : virRunWithHook:857 : internal error '/usr/sbin/dnsmasq --strict-order --bind-interfaces --pid-file=/var/run/libvirt/network/test.pid --conf-file= --listen-address 10.0.1.1 --except-interface lo --dhcp-range 10.0.1.1,10.0.1.14 --dhcp-lease-max=14' exited with non-zero status 5 and signal 0:
dnsmasq: too many stored leases

Expected results:
Should add the network and start the dnsmasq process without error.

Additional info:
Probably the "-l" option to dnsmasq would be useful here to create per network lease files.