Public bug reported:
On Ubuntu 20.04.2 with openvpn 2.4.7-1ubuntu2.20.04.2:
The postinst script for openvpn has the following:
if [ -x "/etc/init.d/openvpn" ]; then
pathfind invoke-rc.d
if [ $? = 0 ]; then
invoke-rc.d openvpn cond-restart || invoke-rc.d openvpn restart
else
/etc/init.d/openvpn cond-restart || /etc/init.d/openvpn restart
fi
fi
and since cond-restart isn't one of start,stop,restart, or try-restart,
invoke-rc.d will kill the openvpn processes managed by systemd and start a new
process using the init.d script. If the systemd service is later restarted,
this results in two processes for the same openvpn configuration that conflict
with each other.
Some ways this could be fixed:
1. Don't run the cond-restart in the postinst script
2. Change inti.d to defer to systemd to start the daemon, at least for
cond-restart
3. Stop using the init.d script altogether.
3. Change the systemd service to make sure to kill conflicting processes as
part of a restart.
** Affects: openvpn (Ubuntu)
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1928367
Title:
openvpn postinst script restarts with init.d, resulting in duplicate
openvpn processes
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/openvpn/+bug/1928367/+subscriptions
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs