A
A
AlexxZhuravlev72017-12-03 20:56:29
openvpn
AlexxZhuravlev7, 2017-12-03 20:56:29

How to make openvpn work after hibernation?

After waking up from sleep mode, openvpn just hangs, there is no internet.
As an option, I'm considering "stopping" openvpn before going to sleep,
and starting it after waking up. How to do it in Ubuntu 16.04 ?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
Moris Haos, 2017-12-04
@morihaos

Hello,
Maybe this will help:
1. Create a file:
2. Content of 000vpn-disable-sleep:

#!/bin/sh
case "$1" in
  suspend|hibernate)
    /bin/pidof openvpn && exit 1
    ;;
esac
exit 0

3. Well, do not forget the rights:
sudo chmod +x /usr/lib/pm-utils/sleep.d/000vpn-disable-sleep

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question