OpenVPN client: âsystmctl stopâ timeout, leftover processes
Clash Royale CLAN TAG#URR8PPP
up vote
0
down vote
favorite
I set up an openvpn client on Ubuntu 18.04 by creating a work.conf
file under /etc/openvpn/
I start it with:
sudo systemctl start openvpn@work.service
When I stop it,
sudo systemctl stop openvpn@work.service
it hangs for exactly 90 seconds before finally shutting down. Checking the logs shows the graceful shutdown timing out, at which point a SIGKILL is issued:
journalctl -n 6 -u openvpn@work.service
12:59:51 systemd[1]: Stopping OpenVPN connection to work...
13:01:21 systemd[1]: openvpn@work.service: State 'stop-sigterm' timed out. Killing.
13:01:21 systemd[1]: openvpn@work.service: Killing process 12379 (openvpn) with signal SIGKILL.
13:01:21 systemd[1]: openvpn@work.service: Main process exited, code=killed, status=9/KILL
13:01:21 systemd[1]: openvpn@work.service: Failed with result 'timeout'.
13:01:21 systemd[1]: Stopped OpenVPN connection to work.
I've noticed a bunch of sleeping openvpn processes, some many days old:
ps ax -o command | grep --count '[o]penvpn'
35
ps ax -o stat,start,command | grep '[S]TAT|[o]penvpn'
STAT STARTED COMMAND
S Aug 21 /bin/bash /etc/openvpn/update-resolv-conf tun0 1500 1553 ... ... init
S Aug 21 run-parts --arg=-a --arg=tun0.openvpn /etc/resolvconf/update.d
...
I see a lot of similar processes in the service's cgroup:
systemd-cgls -u openvpn@work.service | grep --count run-parts
34
systemd-cgls -u openvpn@work.service | grep --count update-resolv-conf
17
I've also noticed that there is an openvpn.service
in addition to my openvpn@work.service
. I'm not clear on the interaction between the two. I think my @work
service is grouped under the other service, but not sure.
I'd like to figure out why the service fails to shutdown cleanly, and how/whether to clean up all those proceses that appear to be duplicates. What would you suggest as a next step?
I can post my conf file if that's useful...
systemd openvpn
add a comment |Â
up vote
0
down vote
favorite
I set up an openvpn client on Ubuntu 18.04 by creating a work.conf
file under /etc/openvpn/
I start it with:
sudo systemctl start openvpn@work.service
When I stop it,
sudo systemctl stop openvpn@work.service
it hangs for exactly 90 seconds before finally shutting down. Checking the logs shows the graceful shutdown timing out, at which point a SIGKILL is issued:
journalctl -n 6 -u openvpn@work.service
12:59:51 systemd[1]: Stopping OpenVPN connection to work...
13:01:21 systemd[1]: openvpn@work.service: State 'stop-sigterm' timed out. Killing.
13:01:21 systemd[1]: openvpn@work.service: Killing process 12379 (openvpn) with signal SIGKILL.
13:01:21 systemd[1]: openvpn@work.service: Main process exited, code=killed, status=9/KILL
13:01:21 systemd[1]: openvpn@work.service: Failed with result 'timeout'.
13:01:21 systemd[1]: Stopped OpenVPN connection to work.
I've noticed a bunch of sleeping openvpn processes, some many days old:
ps ax -o command | grep --count '[o]penvpn'
35
ps ax -o stat,start,command | grep '[S]TAT|[o]penvpn'
STAT STARTED COMMAND
S Aug 21 /bin/bash /etc/openvpn/update-resolv-conf tun0 1500 1553 ... ... init
S Aug 21 run-parts --arg=-a --arg=tun0.openvpn /etc/resolvconf/update.d
...
I see a lot of similar processes in the service's cgroup:
systemd-cgls -u openvpn@work.service | grep --count run-parts
34
systemd-cgls -u openvpn@work.service | grep --count update-resolv-conf
17
I've also noticed that there is an openvpn.service
in addition to my openvpn@work.service
. I'm not clear on the interaction between the two. I think my @work
service is grouped under the other service, but not sure.
I'd like to figure out why the service fails to shutdown cleanly, and how/whether to clean up all those proceses that appear to be duplicates. What would you suggest as a next step?
I can post my conf file if that's useful...
systemd openvpn
add a comment |Â
up vote
0
down vote
favorite
up vote
0
down vote
favorite
I set up an openvpn client on Ubuntu 18.04 by creating a work.conf
file under /etc/openvpn/
I start it with:
sudo systemctl start openvpn@work.service
When I stop it,
sudo systemctl stop openvpn@work.service
it hangs for exactly 90 seconds before finally shutting down. Checking the logs shows the graceful shutdown timing out, at which point a SIGKILL is issued:
journalctl -n 6 -u openvpn@work.service
12:59:51 systemd[1]: Stopping OpenVPN connection to work...
13:01:21 systemd[1]: openvpn@work.service: State 'stop-sigterm' timed out. Killing.
13:01:21 systemd[1]: openvpn@work.service: Killing process 12379 (openvpn) with signal SIGKILL.
13:01:21 systemd[1]: openvpn@work.service: Main process exited, code=killed, status=9/KILL
13:01:21 systemd[1]: openvpn@work.service: Failed with result 'timeout'.
13:01:21 systemd[1]: Stopped OpenVPN connection to work.
I've noticed a bunch of sleeping openvpn processes, some many days old:
ps ax -o command | grep --count '[o]penvpn'
35
ps ax -o stat,start,command | grep '[S]TAT|[o]penvpn'
STAT STARTED COMMAND
S Aug 21 /bin/bash /etc/openvpn/update-resolv-conf tun0 1500 1553 ... ... init
S Aug 21 run-parts --arg=-a --arg=tun0.openvpn /etc/resolvconf/update.d
...
I see a lot of similar processes in the service's cgroup:
systemd-cgls -u openvpn@work.service | grep --count run-parts
34
systemd-cgls -u openvpn@work.service | grep --count update-resolv-conf
17
I've also noticed that there is an openvpn.service
in addition to my openvpn@work.service
. I'm not clear on the interaction between the two. I think my @work
service is grouped under the other service, but not sure.
I'd like to figure out why the service fails to shutdown cleanly, and how/whether to clean up all those proceses that appear to be duplicates. What would you suggest as a next step?
I can post my conf file if that's useful...
systemd openvpn
I set up an openvpn client on Ubuntu 18.04 by creating a work.conf
file under /etc/openvpn/
I start it with:
sudo systemctl start openvpn@work.service
When I stop it,
sudo systemctl stop openvpn@work.service
it hangs for exactly 90 seconds before finally shutting down. Checking the logs shows the graceful shutdown timing out, at which point a SIGKILL is issued:
journalctl -n 6 -u openvpn@work.service
12:59:51 systemd[1]: Stopping OpenVPN connection to work...
13:01:21 systemd[1]: openvpn@work.service: State 'stop-sigterm' timed out. Killing.
13:01:21 systemd[1]: openvpn@work.service: Killing process 12379 (openvpn) with signal SIGKILL.
13:01:21 systemd[1]: openvpn@work.service: Main process exited, code=killed, status=9/KILL
13:01:21 systemd[1]: openvpn@work.service: Failed with result 'timeout'.
13:01:21 systemd[1]: Stopped OpenVPN connection to work.
I've noticed a bunch of sleeping openvpn processes, some many days old:
ps ax -o command | grep --count '[o]penvpn'
35
ps ax -o stat,start,command | grep '[S]TAT|[o]penvpn'
STAT STARTED COMMAND
S Aug 21 /bin/bash /etc/openvpn/update-resolv-conf tun0 1500 1553 ... ... init
S Aug 21 run-parts --arg=-a --arg=tun0.openvpn /etc/resolvconf/update.d
...
I see a lot of similar processes in the service's cgroup:
systemd-cgls -u openvpn@work.service | grep --count run-parts
34
systemd-cgls -u openvpn@work.service | grep --count update-resolv-conf
17
I've also noticed that there is an openvpn.service
in addition to my openvpn@work.service
. I'm not clear on the interaction between the two. I think my @work
service is grouped under the other service, but not sure.
I'd like to figure out why the service fails to shutdown cleanly, and how/whether to clean up all those proceses that appear to be duplicates. What would you suggest as a next step?
I can post my conf file if that's useful...
systemd openvpn
systemd openvpn
asked Aug 26 at 18:04
ivan
662719
662719
add a comment |Â
add a comment |Â
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f464948%2fopenvpn-client-systmctl-stop-timeout-leftover-processes%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password