[ovs-dev] [PATCH] rhel: Stop managing the /run/openvswitch directory with systemd.

Aaron Conole aconole at redhat.com
Tue Mar 27 13:34:48 UTC 2018


Markos Chandras <mchandras at suse.de> writes:

> It appears that new systemd versions (tested with v237) changed the
> way RuntimeDirectory option behaves. Upstream commit 3536f49e8fa2
> ("core: add {State,Cache,Log,Configuration}Directory=") modified the
> RuntimeDirectory code to run before every ExecStart* command instead
> of running it once per service file when the service is run as 'root'.
>
> This breaks the ovsdb-server because after the chown command was applied,
> the RuntimeDirectory code was executed again, effectively wiping the
> /run/openvswitch directory and creating it again resulting in the
> following problem.
>
> |00002|daemon_unix|EMER|/var/run/openvswitch/ovsdb-server.pid.tmp: create failed (Permission denied)
> Mar 19 16:37:20 susetest ovs-ctl[3045]: ovsdb-server: /var/run/openvswitch/ovsdb-server.pid.tmp: create failed (Permission denied)
> Mar 19 16:37:20 susetest ovs-ctl[3045]: Starting ovsdb-server ... failed!
>
> The ovs-lib code can already manage that directory for us so we can
> remove these entries from the systemd file and let ovs-vsctl do it.
>
> Cc: Aaron Conole <aconole at redhat.com>
> Signed-off-by: Markos Chandras <mchandras at suse.de>
> ---

Systemd has fixed this with commit:

30c81ce2cef9 ("pid1: when creating service directories, don't chown existing files")

Which was caught thanks to some proactive testing:

https://bugzilla.redhat.com/show_bug.cgi?id=1508495

I think we probably don't need this fix, provided downstream versions
backport that commit.


More information about the dev mailing list