networking restart trouble with libvirt

Kernels & Hardware, configuring network, installing services

networking restart trouble with libvirt

Postby bergentroll » 2018-05-23 05:34

I have a pair of Debian 9.4 servers each with pair of 1G intel interfaces. Servers using as QEMU/KVM hypervisors. Its work fine but after
Code: Select all
# systemctl restart networking
the network on virtual hosts is broken (while hypervisor's link is OK).

Hypervisors /etc/network/interfaces like this:
Code: Select all
auto lo
iface lo inet loopback

# The primary network interface
#auto enp5s0f0
iface enp5s0f0 inet manual

auto br0
iface br0 inet dhcp
    bridge_ports enp5s0f0
    bridge_stp off
    bridge_waitport 0
    bridge_fd 0


Piece of dumpxml from one of the vritual machines:
Code: Select all
    <interface type='bridge'>
      <mac address='52:54:00:b7:bc:04'/>
      <source bridge='br0'/>
      <target dev='vnet0'/>
      <model type='e1000'/>
      <alias name='net0'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x0'/>
    </interface>


Code: Select all
$ virsh iface-dumpxml br0
<interface type='bridge' name='br0'>
  <protocol family='ipv4'>
    <ip address='192.168.1.109' prefix='24'/>
  </protocol>
  <protocol family='ipv6'>
    <ip address='fe80::215:17ff:fe53:8850' prefix='64'/>
  </protocol>
  <bridge>
    <interface type='ethernet' name='vnet0'>
      <link state='unknown'/>
      <mac address='fe:54:00:b7:bc:04'/>
    </interface>
    <interface type='ethernet' name='enp5s0f0'>
      <link speed='1000' state='up'/>
      <mac address='00:15:17:53:88:50'/>
    </interface>
  </bridge>
</interface>


Piece of "journalctl -u networking" command output (in this time there is a networking restart):
Code: Select all
-- Reboot --
май 23 11:08:32 hypervisor2 systemd[1]: Starting Raise network interfaces...
май 23 11:08:32 hypervisor2 ifup[489]: Waiting for a max of 0 seconds for enp5s0f0 to become available.
май 23 11:08:32 hypervisor2 ifup[489]: Waiting for br0 to get ready (MAXWAIT is 2 seconds).
май 23 11:08:33 hypervisor2 dhclient[553]: Internet Systems Consortium DHCP Client 4.3.5
май 23 11:08:33 hypervisor2 ifup[489]: Internet Systems Consortium DHCP Client 4.3.5
май 23 11:08:33 hypervisor2 ifup[489]: Copyright 2004-2016 Internet Systems Consortium.
май 23 11:08:33 hypervisor2 ifup[489]: All rights reserved.
май 23 11:08:33 hypervisor2 ifup[489]: For info, please visit https://www.isc.org/software/dhcp/
май 23 11:08:33 hypervisor2 dhclient[553]: Copyright 2004-2016 Internet Systems Consortium.
май 23 11:08:33 hypervisor2 dhclient[553]: All rights reserved.
май 23 11:08:33 hypervisor2 dhclient[553]: For info, please visit https://www.isc.org/software/dhcp/
май 23 11:08:33 hypervisor2 dhclient[553]:
май 23 11:08:33 hypervisor2 dhclient[553]: Listening on LPF/br0/00:15:17:53:88:50
май 23 11:08:33 hypervisor2 ifup[489]: Listening on LPF/br0/00:15:17:53:88:50
май 23 11:08:33 hypervisor2 ifup[489]: Sending on   LPF/br0/00:15:17:53:88:50
май 23 11:08:33 hypervisor2 ifup[489]: Sending on   Socket/fallback
май 23 11:08:33 hypervisor2 ifup[489]: DHCPDISCOVER on br0 to 255.255.255.255 port 67 interval 7
май 23 11:08:33 hypervisor2 dhclient[553]: Sending on   LPF/br0/00:15:17:53:88:50
май 23 11:08:33 hypervisor2 dhclient[553]: Sending on   Socket/fallback
май 23 11:08:33 hypervisor2 dhclient[553]: DHCPDISCOVER on br0 to 255.255.255.255 port 67 interval 7
май 23 11:08:40 hypervisor2 dhclient[553]: DHCPDISCOVER on br0 to 255.255.255.255 port 67 interval 15
май 23 11:08:40 hypervisor2 ifup[489]: DHCPDISCOVER on br0 to 255.255.255.255 port 67 interval 15
май 23 11:08:55 hypervisor2 dhclient[553]: DHCPDISCOVER on br0 to 255.255.255.255 port 67 interval 7
май 23 11:08:55 hypervisor2 ifup[489]: DHCPDISCOVER on br0 to 255.255.255.255 port 67 interval 7
май 23 11:09:02 hypervisor2 dhclient[553]: DHCPDISCOVER on br0 to 255.255.255.255 port 67 interval 19
май 23 11:09:02 hypervisor2 ifup[489]: DHCPDISCOVER on br0 to 255.255.255.255 port 67 interval 19
май 23 11:09:21 hypervisor2 dhclient[553]: DHCPDISCOVER on br0 to 255.255.255.255 port 67 interval 13
май 23 11:09:21 hypervisor2 ifup[489]: DHCPDISCOVER on br0 to 255.255.255.255 port 67 interval 13
май 23 11:09:21 hypervisor2 dhclient[553]: DHCPREQUEST of 192.168.1.109 on br0 to 255.255.255.255 port 67
май 23 11:09:21 hypervisor2 ifup[489]: DHCPREQUEST of 192.168.1.109 on br0 to 255.255.255.255 port 67
май 23 11:09:21 hypervisor2 ifup[489]: DHCPOFFER of 192.168.1.109 from 10.74.7.1
май 23 11:09:21 hypervisor2 dhclient[553]: DHCPOFFER of 192.168.1.109 from 10.74.7.1
май 23 11:09:21 hypervisor2 dhclient[553]: DHCPACK of 192.168.1.109 from 10.74.7.1
май 23 11:09:21 hypervisor2 ifup[489]: DHCPACK of 192.168.1.109 from 10.74.7.1
май 23 11:09:22 hypervisor2 ifup[489]: bound to 192.168.1.109 -- renewal in 8748 seconds.
май 23 11:09:22 hypervisor2 systemd[1]: Started Raise network interfaces.
...skipping...
май 23 11:06:48 hypervisor2 ifdown[1266]: All rights reserved.
май 23 11:06:48 hypervisor2 ifdown[1266]: For info, please visit https://www.isc.org/software/dhcp/
май 23 11:06:48 hypervisor2 dhclient[1296]: All rights reserved.
май 23 11:06:48 hypervisor2 dhclient[1296]: For info, please visit https://www.isc.org/software/dhcp/
май 23 11:06:48 hypervisor2 dhclient[1296]:
май 23 11:06:48 hypervisor2 dhclient[1296]: Listening on LPF/br0/00:15:17:53:88:50
май 23 11:06:48 hypervisor2 ifdown[1266]: Listening on LPF/br0/00:15:17:53:88:50
май 23 11:06:48 hypervisor2 ifdown[1266]: Sending on   LPF/br0/00:15:17:53:88:50
май 23 11:06:48 hypervisor2 ifdown[1266]: Sending on   Socket/fallback
май 23 11:06:48 hypervisor2 dhclient[1296]: Sending on   LPF/br0/00:15:17:53:88:50
май 23 11:06:48 hypervisor2 dhclient[1296]: Sending on   Socket/fallback
май 23 11:06:48 hypervisor2 dhclient[1296]: DHCPRELEASE on br0 to 10.74.7.1 port 67
май 23 11:06:48 hypervisor2 ifdown[1266]: DHCPRELEASE on br0 to 10.74.7.1 port 67
май 23 11:06:49 hypervisor2 systemd[1]: Stopped Raise network interfaces.
-- Reboot --


I also tried using only static addresses, but it take no effect.

Also if br0 before netwokring restart had in output of "ip links" command index e. g. 4, index increments to 5 after networking restart.

What can be wrong with my networking?
User avatar
bergentroll
 
Posts: 1
Joined: 2018-05-23 03:27

Re: networking restart trouble with libvirt

Postby lbm » 2018-05-28 08:16

You restart the KVM host, and then the guests are unable to contact the host afterwards, is that correct understood ?
I've had issues sometimes, with routing changing, if I restart the network. (even though its not really KVM related).
User avatar
lbm
 
Posts: 484
Joined: 2009-05-16 09:24
Location: Denmark


Return to System configuration

Who is online

Users browsing this forum: No registered users and 7 guests

fashionable