Description of problem:
When starting openvpn with the new openvpn-server@instance unit on a fresh install, it fails complaining about /run/openvpn-server/status-instance.log not existing.
Indeed the directory /run/openvpn-server does not exist.
After a reboot, the directory has been created.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. yum install openvpn
2. Create openvpn config in /etc/openvpn/server/instance.conf
3. systemctl start openvpn-server@instance
4. journalctl -n 50 -u openvpn-server@instance
systemd: Starting OpenVPN service for ovashrai4...
openvpn: disabling NCP mode (--ncp-disable) because not in P2MP client or server mode
openvpn: Options error: --status fails with '/run/openvpn-server/status-ovashrai4.log': No such file or directory
openvpn: Options error: Please correct these errors.
openvpn: Use --help for more information.
systemd: firstname.lastname@example.org: main process exited, code=exited, status=1/FAILURE
systemd: Failed to start OpenVPN service for ovashrai4.
systemd: Unit email@example.com entered failed state.
systemd: firstname.lastname@example.org failed.
Initialization Sequence Completed
The issue would appear to be that while /usr/lib/tmpfiles.d/openvpn.conf is packaged that defines this (and the /run/openvpn-client) directory, package install does not trigger their creation.
Possible solution would be to add the following in post-install:
systemd-tmpfiles --create openvpn.conf
Generally one should include those files in the package itself, such as by creating them in %install like the example in the tmpfiles.d wiki page does. That helps ensure rpm can track their ownership and makes removal work the way people expect.
openvpn-2.4.2-2.el7 has been submitted as an update to Fedora EPEL 7. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2017-c9f915d837
A similar fix is coming to F25, F26 and Rawhide as well.
openvpn-2.4.2-2.el7 has been pushed to the Fedora EPEL 7 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2017-c9f915d837
openvpn-2.4.2-2.el7 has been pushed to the Fedora EPEL 7 stable repository. If problems still persist, please make note of it in this bug report.