From: Christian Hesse <[email protected]> Different unit instances create and destroy the same RuntimeDirectory. This leads to running instances where the status file (and possibly more runtime data) is no longer accessible.
So create a RuntimeDirectory per instance. Signed-off-by: Christian Hesse <[email protected]> --- distro/systemd/[email protected] | 2 +- distro/systemd/[email protected] | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/distro/systemd/[email protected] b/distro/systemd/[email protected] index 5618af3..fcb5302 100644 --- a/distro/systemd/[email protected] +++ b/distro/systemd/[email protected] @@ -9,7 +9,7 @@ Documentation=https://community.openvpn.net/openvpn/wiki/HOWTO [Service] Type=notify PrivateTmp=true -RuntimeDirectory=openvpn-client +RuntimeDirectory=openvpn-client@%i RuntimeDirectoryMode=0710 WorkingDirectory=/etc/openvpn/client ExecStart=/usr/sbin/openvpn --suppress-timestamps --nobind --config %i.conf diff --git a/distro/systemd/[email protected] b/distro/systemd/[email protected] index b9b4dba..8b240cf 100644 --- a/distro/systemd/[email protected] +++ b/distro/systemd/[email protected] @@ -9,10 +9,10 @@ Documentation=https://community.openvpn.net/openvpn/wiki/HOWTO [Service] Type=notify PrivateTmp=true -RuntimeDirectory=openvpn-server +RuntimeDirectory=openvpn-server@%i RuntimeDirectoryMode=0710 WorkingDirectory=/etc/openvpn/server -ExecStart=/usr/sbin/openvpn --status %t/openvpn-server/status-%i.log --status-version 2 --suppress-timestamps --config %i.conf +ExecStart=/usr/sbin/openvpn --status %t/openvpn-server@%i/status.log --status-version 2 --suppress-timestamps --config %i.conf CapabilityBoundingSet=CAP_IPC_LOCK CAP_NET_ADMIN CAP_NET_BIND_SERVICE CAP_NET_RAW CAP_SETGID CAP_SETUID CAP_SYS_CHROOT CAP_DAC_OVERRIDE LimitNPROC=10 DeviceAllow=/dev/null rw -- 2.11.0 ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, SlashDot.org! http://sdm.link/slashdot _______________________________________________ Openvpn-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/openvpn-devel
