Ask Your Question
2

Does F16 no longer support starting openvpn as a service?

asked 2011-11-12 11:02:16 -0500

the.kid gravatar image

It looks like Fedora 16 not longer supports openvpn as a "service". Is this the case, and if so what is the new recommended way of starting openvpn as system startup. I could not find any systemd or chkconfig scripts to manage it.

To get around this I ended up having to copy a chkconfig script from another system. As I'm trying to get into the habit of using systemd rather than chkconfig, I'd like to know the recommended approach.

edit retag flag offensive close merge delete

3 Answers

Sort by ยป oldest newest most voted
1

answered 2012-04-21 08:10:37 -0500

TobyGoodwin gravatar image

Sure it does, although the user tools don't quite work as smoothly as you'd hope.

I have an openvpn tunnel tun427 (so its configuration is in /etc/openvpn/tun427.conf and its key in /etc/openvpn/tun427.key).

To start this:

systemctl start openvpn@tun427.service

to stop it:

systemctl stop openvpn@tun427.service

But to automatically start it at boot time, you can't say systemctl enable openvpn@tun427.service. (I think this is probably a bug.) Instead, make the link manually:

ln -s /lib/systemd/system/openvpn@.service /etc/systemd/system/multi-user.target.wants/openvpn@tun427.service

Hope this helps,

#t

edit flag offensive delete link more

Comments

This doesn't work for me. Calling the enable command still results in "Failed to issue method call: No such file or directory"

Cerin gravatar imageCerin ( 2013-03-04 10:40:53 -0500 )edit
1

answered 2011-11-12 12:37:10 -0500

hhlp gravatar image

updated 2011-11-12 13:37:35 -0500

have you tried this :

Used to list the services that can be started or stopped

ls /lib/systemd/system/*.service 
ls /etc/systemd/system/*.service

Used to start a service (not reboot persistent)

systemctl start fro.service

Used to stop a service (not reboot persistent)

systemctl stop fro.service

Turn the service on, for start at next boot, or other trigger.

systemctl enable fro.service

Turn the service off for the next reboot, or any other trigger.

systemctl disable fro.service
edit flag offensive delete link more
0

answered 2011-11-12 19:28:39 -0500

the.kid gravatar image

My question was around the fact that no systemd (or chkconfig) service scripts were created for openvpn after I installed it. However, I now think that openvpn probably never included a service script, and that I had probably got the chkconfig script that I've used in the past from the Internet.

The script exists here for anybody that might be looking: https://community.openvpn.net/openvpn/browser/sample-scripts/openvpn.init

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

2 followers

Stats

Asked: 2011-11-12 11:02:16 -0500

Seen: 3,103 times

Last updated: Apr 21 '12