Openvswitch issue during boot

belette

New Member
Oct 20, 2014
14
0
1
(PVE from ISO 3.3 / Kernel 3.10.0-4-pve / OVS 2.3.0-1 )

Hi,

During the boot process I can see (unix:/var/run/openvswitch/db.sock: database connection failed (No such file or directory) everytime OVS try to do an action, it is like networking process is starting after it. To double check, after booting and doing a /etc/init.d/networking restart everyting is allright and my OVS is running well with all I set on /etc/network/interfaces.

I checked and the OVS 3.3 is patched so I don't know what can still avoid OVS to start properly?

Many thanks,
 
Is that a new proxmox installation from CD, or have you previously installed old OVS package from debian repository?
 
Hi Dietmar,

From CD, fresh new installation. Only done a kernel update (3.10) & OVS (2.3.0) all from PVE repository.
I have search on old posts and saw your reply regarding a patch for init but I doubled checked and the patch is here.
 
I encountered the same problem on my Promox 3.3 (Kernel 2.6.32-34, openvswitch 2.3.0-1). The OVS network configuration does not load on boot but works perfectly when doing a service networking restart.

I saw in /var/log/boot that ovsdb-server and ovs-vswitchd are started after the networking initialization which I think should be the other way round (and is also so defined in the X-Start-Before parameter in the init script). However, I'm no extpert for init scripts and my experiments didn't work :confused:

Code:
# cat /var/log/boot | grep ovsSat Nov 29 01:36:03 2014: Configuring network interfaces...ovs-vsctl: ovs|00001|vsctl|INFO|Called as ovs-vsctl --timeout=5 -- --may-exist add-br vmbr0 --
Sat Nov 29 01:36:04 2014: ovs-vsctl: ovs|00002|vsctl|ERR|unix:/var/run/openvswitch/db.sock: database connection failed (No such file or directory)
Sat Nov 29 01:36:04 2014: ovs-vsctl: unix:/var/run/openvswitch/db.sock: database connection failed (No such file or directory)
Sat Nov 29 01:36:04 2014: ovs-vsctl: ovs|00001|vsctl|INFO|Called as ovs-vsctl --timeout=5 -- --fake-iface add-bond vmbr0 bond0 eth0 eth1 bond_mode=active-backup --
Sat Nov 29 01:36:04 2014: ovs-vsctl: ovs|00002|vsctl|ERR|unix:/var/run/openvswitch/db.sock: database connection failed (No such file or directory)
Sat Nov 29 01:36:04 2014: ovs-vsctl: unix:/var/run/openvswitch/db.sock: database connection failed (No such file or directory)
Sat Nov 29 01:36:04 2014: ovs-vsctl: ovs|00001|vsctl|INFO|Called as ovs-vsctl --timeout=5 -- --may-exist add-port vmbr0 vlan1 tag=1 -- set Interface vlan1 type=internal -- set interface vlan1 external-ids:iface-id=proxmox2-vlan1-vif
Sat Nov 29 01:36:04 2014: ovs-vsctl: ovs|00002|vsctl|ERR|unix:/var/run/openvswitch/db.sock: database connection failed (No such file or directory)
Sat Nov 29 01:36:04 2014: ovs-vsctl: unix:/var/run/openvswitch/db.sock: database connection failed (No such file or directory)
Sat Nov 29 01:36:04 2014: ovs-vsctl: ovs|00001|vsctl|INFO|Called as ovs-vsctl --timeout=5 -- --may-exist add-port vmbr0 vlan10 tag=10 -- set Interface vlan10 type=internal -- set interface vlan10 external-ids:iface-id=proxmox2-vlan10-vif
Sat Nov 29 01:36:04 2014: ovs-vsctl: ovs|00002|vsctl|ERR|unix:/var/run/openvswitch/db.sock: database connection failed (No such file or directory)
Sat Nov 29 01:36:04 2014: ovs-vsctl: unix:/var/run/openvswitch/db.sock: database connection failed (No such file or directory)
Sat Nov 29 01:36:07 2014: ovs-vsctl: ovs|00001|vsctl|INFO|Called as ovs-vsctl --no-wait -- init -- set Open_vSwitch . db-version=7.6.0
Sat Nov 29 01:36:08 2014: Starting ovsdb-server.
Sat Nov 29 01:36:08 2014: Starting ovs-vswitchd.
 
Hi BeeFGee

It is like we encounter the same issue..
It is strange that this is not affecting more people..
Have you find a workaround?
 
Hey belette,

actually I really found a nice workaround after messing some time around with the init scripts and not coming to a solution:

Add the following line to root's crontab (crontab -e):

Code:
@reboot /usr/sbin/service networking restart

The special @reboot time alias will run the command once after every reboot. Works perfectly fine for my headless machine with OVS configured.

Unfortunately I'm missing the necessary know-how to provide a proper solution, but I hope dietmar or someone else will have a look into this and can provide it in the next versions.