Description of problem: conf.db is by default at /etc/openvswitch. It should be at /var/lib/openvswitch , like ovnnb_db.db and ovnsb_db.db . This is a database file. /etc is for configuration files. I see that /etc/openvswitch is owned by openvswitch:openvswitch (and that ovsdb-server runs as user openvswitch), whereas /var/lib/openvswitch is owned by root:root (and that at least ovn-northd runs as root). I do not know much about OVS/OVN, nor specifically about its security model etc., so not sure what must run as root etc. For doing a minimal change, just for current bug, I tested this, and it seems to work: mkdir /var/lib/openvswitch/ovsdb chown openvswitch:openvswitch /var/lib/openvswitch/ovsdb Add to /usr/lib/systemd/system/ovsdb-server.service this line, after [Service]: Environment=OVS_DBDIR=/var/lib/openvswitch/ovsdb Now, all services manage to start and use their db files under /var/lib/openvswitch.
(In reply to Yedidyah Bar David from comment #0) > Description of problem: > > conf.db is by default at /etc/openvswitch. > > It should be at /var/lib/openvswitch , like ovnnb_db.db and ovnsb_db.db . > > This is a database file. /etc is for configuration files. > > I see that /etc/openvswitch is owned by openvswitch:openvswitch (and that > ovsdb-server runs as user openvswitch), whereas /var/lib/openvswitch is > owned by root:root (and that at least ovn-northd runs as root). I do not > know much about OVS/OVN, nor specifically about its security model etc., so > not sure what must run as root etc. For doing a minimal change, just for > current bug, I tested this, and it seems to work: On recent ovn builds (since 2.11.1-30) also ovn runs as non-root user > mkdir /var/lib/openvswitch/ovsdb > chown openvswitch:openvswitch /var/lib/openvswitch/ovsdb > > Add to /usr/lib/systemd/system/ovsdb-server.service this line, after > [Service]: > > Environment=OVS_DBDIR=/var/lib/openvswitch/ovsdb > > Now, all services manage to start and use their db files under > /var/lib/openvswitch.
I see that debian does something similar, they symlink conf.db from /var/lib/openvswitch to /etc/openvswitch for backward compatibility: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=681880
Patch sent upstream