Openvpn: how to start at login?

Marko Vojinovic vvmarko at gmail.com
Sun Aug 26 00:27:13 UTC 2012


On Sunday, 26. August 2012. 0.00.16 Timothy Murphy wrote:
> Marko Vojinovic wrote:
> > In what sense openvpn *doesn't* run like every other service?
> 
> Before systemd/systemctl came along
> I just used to say "chkconfig openvpn on".
> I'm just asking why I can't do the equivalent today?
> 
> As far as I know, one can "systemctl enable" every other service.

Well, if you take another look at the link I gave you,

  http://fedoraproject.org/wiki/Openvpn#Working_with_systemd

you will see that after the server setup instructions, there are also the 
client setup instructions. Assuming that you have already configured keys and 
the openvpn configuration file /etc/openvpn/MyClient.conf, you might be 
interested in these particular steps:

4. cd /lib/systemd/system
5. ln openvpn at .service openvpn at MyClient.service
6. systemctl enable openvpn at MyClient.service
7. systemctl start openvpn at MyClient.service 

This worked for me, openvpn client service starts automatically at boot, and 
never shuts down. If it doesn't work for you, look at /var/log/messages and 
tell us what went wrong.

HTH, :-)
Marko





More information about the users mailing list