[Pkg-libvirt-maintainers] Bug#626166: virt-manager: Fails to create nat-ed network on host
Olivier Berger
olivier.berger at it-sudparis.eu
Mon May 9 15:01:07 UTC 2011
On Mon, May 09, 2011 at 03:02:07PM +0200, Olivier Berger wrote:
>
> Hi.
>
> This looks similar to what is reported in #615907, but relates to NAT-ed local network.
>
> Here's the traceback I get when I create a "default" network with these parameters :
> 192.168.122.0/24
> gateway : 192.168.122.1
> netwmask : 255.255.255.0
> with DHCP betw :
> 192.168.122.128
> 192.168.122.254
> connectivity : NAT
>
> I get :
> Error creating virtual network: internal error Child process (dnsmasq --strict-order --bind-interfaces --pid-file=/var/run/libvirt/network/default.pid --conf-file= --except-interface lo --listen-address 192.168.122.1 --dhcp-range 192.168.122.128,192.168.122.254 --dhcp-leasefile=/var/lib/libvirt/dnsmasq/default.leases --dhcp-lease-max=127 --dhcp-no-override) status unexpected: exit status 2
>
> Traceback (most recent call last):
> File "/usr/share/virt-manager/virtManager/createnet.py", line 351, in finish
> self.conn.create_network(xml)
> File "/usr/share/virt-manager/virtManager/connection.py", line 743, in create_network
> net.create()
> File "/usr/lib/python2.6/dist-packages/libvirt.py", line 1001, in create
> if ret == -1: raise libvirtError ('virNetworkCreate() failed', net=self)
> libvirtError: internal error Child process (dnsmasq --strict-order --bind-interfaces --pid-file=/var/run/libvirt/network/default.pid --conf-file= --except-interface lo --listen-address 192.168.122.1 --dhcp-range 192.168.122.128,192.168.122.254 --dhcp-leasefile=/var/lib/libvirt/dnsmasq/default.leases --dhcp-lease-max=127 --dhcp-no-override) status unexpected: exit status 2
>
I believe the problem is caused by libvirt not shutting down dnsmasq.
I seem to have had a previous configuration, that I had deleted, which used the same network. Even though I had restarted libvirt-bin in between, dnsmasq wouldn't be killed, so it somehow was refusing to start with same network again, AFAICT.
Shutting down dnsmasq when a network is stopped / removed and when libvirt daemon is shut down would fix the issue, IMHO.
Hope this helps.
Best regards,
More information about the Pkg-libvirt-maintainers
mailing list