First of all, I have one Xenial node where open vswitch worked, guessing that that time open vswitch daemon started before trying to setup network.
And then on other machines it doesn't work cause the daemon isn't started before trying to setup networking.
Here are the logs from a broken system.
```
Sep 12 16:11:07 vm10 systemd[1]: Reached target Network.
Sep 12 16:11:07 vm10 systemd[1]: networking.service: Failed with result 'exit-code'.
Sep 12 16:11:07 vm10 systemd[1]: networking.service: Unit entered failed state.
Sep 12 16:11:07 vm10 systemd[1]: Failed to start Raise network interfaces.
Sep 12 16:11:07 vm10 systemd[1]: networking.service: Main process exited, code=exited, status=1/FAILURE
Sep 12 16:11:07 vm10 ntpdate[3027]: no servers can be used, exiting
Sep 12 16:11:07 vm10 ifup[2858]: Failed to bring up br0.
Sep 12 16:11:07 vm10 ifup[2858]: Cannot find device "br0"
Sep 12 16:11:07 vm10 ifup[2858]: Failed to bring up mgm.
Sep 12 16:11:07 vm10 ifup[2858]: Cannot find device "mgm"
Sep 12 16:11:07 vm10 ifup[2858]: mgm: ERROR while getting interface flags: No such device
Sep 12 16:11:07 vm10 ifup[2858]: ovs-vsctl: unix:/var/run/openvswitch/db.sock: database connection failed (No such file or directory)
Sep 12 16:11:07 vm10 ovs-vsctl[2991]: ovs|00002|db_ctl_base|ERR|unix:/var/run/openvswitch/db.sock: database connection failed (No such file or directory)
Sep 12 16:11:07 vm10 ovs-vsctl[2991]: ovs|00001|vsctl|INFO|Called as ovs-vsctl --timeout=5 -- --may-exist add-port br0 mgm vlan_mode=access -- set Interface mgm type=internal -- set interface mgm external-ids:iface-id=vm10-mgm-vif
Sep 12 16:11:07 vm10 ifup[2858]: Failed to bring up bond0.
Sep 12 16:11:07 vm10 ifup[2858]: Cannot find device "bond0"
Sep 12 16:11:07 vm10 kernel: bnx2x 0000:01:00.1 em2: NIC Link is Up, 10000 Mbps full duplex, Flow control: none
Sep 12 16:11:06 vm10 kernel: bnx2x 0000:01:00.1 em2: using MSI-X IRQs: sp 50 fp[0] 52 ... fp[7] 59
Sep 12 16:11:06 vm10 kernel: bnx2x 0000:01:00.0 em1: NIC Link is Up, 10000 Mbps full duplex, Flow control: none
Sep 12 16:11:06 vm10 kernel: bnx2x 0000:01:00.0 em1: using MSI-X IRQs: sp 39 fp[0] 41 ... fp[7] 48
Sep 12 16:11:05 vm10 ifup[2858]: bond0: ERROR while getting interface flags: No such device
Sep 12 16:11:05 vm10 ifup[2858]: ovs-vsctl: unix:/var/run/openvswitch/db.sock: database connection failed (No such file or directory)
Sep 12 16:11:05 vm10 ovs-vsctl[2922]: ovs|00002|db_ctl_base|ERR|unix:/var/run/openvswitch/db.sock: database connection failed (No such file or directory)
Sep 12 16:11:05 vm10 ovs-vsctl[2922]: ovs|00001|vsctl|INFO|Called as ovs-vsctl --timeout=5 -- --fake-iface add-bond br0 bond0 em1 em2 vlan_mode=native-untagged bond_mode=balance-tcp lacp=active other_config:lacp-time=fast --
Sep 12 16:11:05 vm10 ifup[2858]: ovs-vsctl: unix:/var/run/openvswitch/db.sock: database connection failed (No such file or directory)
Sep 12 16:11:05 vm10 ovs-vsctl[2908]: ovs|00002|db_ctl_base|ERR|unix:/var/run/openvswitch/db.sock: database connection failed (No such file or directory)
Sep 12 16:11:05 vm10 ovs-vsctl[2908]: ovs|00001|vsctl|INFO|Called as ovs-vsctl --timeout=5 -- --may-exist add-br br0 --
Sep 12 16:11:05 vm10 systemd[1]: Starting Raise network interfaces...
```
I might as well just add some facts and my logs.
First of all, I have one Xenial node where open vswitch worked, guessing that that time open vswitch daemon started before trying to setup network.
And then on other machines it doesn't work cause the daemon isn't started before trying to setup networking.
Here are the logs from a broken system. run/openvswitch /db.sock: database connection failed (No such file or directory) db_ctl_ base|ERR| unix:/var/ run/openvswitch /db.sock: database connection failed (No such file or directory) vsctl|INFO| Called as ovs-vsctl --timeout=5 -- --may-exist add-port br0 mgm vlan_mode=access -- set Interface mgm type=internal -- set interface mgm external- ids:iface- id=vm10- mgm-vif run/openvswitch /db.sock: database connection failed (No such file or directory) db_ctl_ base|ERR| unix:/var/ run/openvswitch /db.sock: database connection failed (No such file or directory) vsctl|INFO| Called as ovs-vsctl --timeout=5 -- --fake-iface add-bond br0 bond0 em1 em2 vlan_mode= native- untagged bond_mode= balance- tcp lacp=active other_config: lacp-time= fast -- run/openvswitch /db.sock: database connection failed (No such file or directory) db_ctl_ base|ERR| unix:/var/ run/openvswitch /db.sock: database connection failed (No such file or directory) vsctl|INFO| Called as ovs-vsctl --timeout=5 -- --may-exist add-br br0 --
```
Sep 12 16:11:07 vm10 systemd[1]: Reached target Network.
Sep 12 16:11:07 vm10 systemd[1]: networking.service: Failed with result 'exit-code'.
Sep 12 16:11:07 vm10 systemd[1]: networking.service: Unit entered failed state.
Sep 12 16:11:07 vm10 systemd[1]: Failed to start Raise network interfaces.
Sep 12 16:11:07 vm10 systemd[1]: networking.service: Main process exited, code=exited, status=1/FAILURE
Sep 12 16:11:07 vm10 ntpdate[3027]: no servers can be used, exiting
Sep 12 16:11:07 vm10 ifup[2858]: Failed to bring up br0.
Sep 12 16:11:07 vm10 ifup[2858]: Cannot find device "br0"
Sep 12 16:11:07 vm10 ifup[2858]: Failed to bring up mgm.
Sep 12 16:11:07 vm10 ifup[2858]: Cannot find device "mgm"
Sep 12 16:11:07 vm10 ifup[2858]: mgm: ERROR while getting interface flags: No such device
Sep 12 16:11:07 vm10 ifup[2858]: ovs-vsctl: unix:/var/
Sep 12 16:11:07 vm10 ovs-vsctl[2991]: ovs|00002|
Sep 12 16:11:07 vm10 ovs-vsctl[2991]: ovs|00001|
Sep 12 16:11:07 vm10 ifup[2858]: Failed to bring up bond0.
Sep 12 16:11:07 vm10 ifup[2858]: Cannot find device "bond0"
Sep 12 16:11:07 vm10 kernel: bnx2x 0000:01:00.1 em2: NIC Link is Up, 10000 Mbps full duplex, Flow control: none
Sep 12 16:11:06 vm10 kernel: bnx2x 0000:01:00.1 em2: using MSI-X IRQs: sp 50 fp[0] 52 ... fp[7] 59
Sep 12 16:11:06 vm10 kernel: bnx2x 0000:01:00.0 em1: NIC Link is Up, 10000 Mbps full duplex, Flow control: none
Sep 12 16:11:06 vm10 kernel: bnx2x 0000:01:00.0 em1: using MSI-X IRQs: sp 39 fp[0] 41 ... fp[7] 48
Sep 12 16:11:05 vm10 ifup[2858]: bond0: ERROR while getting interface flags: No such device
Sep 12 16:11:05 vm10 ifup[2858]: ovs-vsctl: unix:/var/
Sep 12 16:11:05 vm10 ovs-vsctl[2922]: ovs|00002|
Sep 12 16:11:05 vm10 ovs-vsctl[2922]: ovs|00001|
Sep 12 16:11:05 vm10 ifup[2858]: ovs-vsctl: unix:/var/
Sep 12 16:11:05 vm10 ovs-vsctl[2908]: ovs|00002|
Sep 12 16:11:05 vm10 ovs-vsctl[2908]: ovs|00001|
Sep 12 16:11:05 vm10 systemd[1]: Starting Raise network interfaces...
```