Page 1 of 1

OpenVPN does not listen (on any port)

Posted: Sat Sep 01, 2018 2:54 pm
by julo
Hello,

I am trying to setup OpenVPN server on Debian and found out that OpenVPN service does not listen on any port. I t does not work even with the very simple configuration from Mini HowTo (https://openvpn.net/index.php/open-sour ... howto.html), just switched to TCP.

My configuration file is like this (I generated static key).

server config

dev tun
proto tcp
ifconfig 10.8.0.1 10.8.0.2
secret static.key


When I start OpenVPN using "systemstl start openvpn", it does not listen on on any port (should listen on TCP 1194), verified by "netstat -nlp".

output from "systemstl status openvpn" is like this, so OpenVPN server is running.
‚óŹ openvpn.service - OpenVPN service
Loaded: loaded (/lib/systemd/system/openvpn.service; enabled)
Active: active (exited) since Sat 2018-09-01 16:44:19 CEST; 1min 51s ago
Process: 17724 ExecStart=/bin/true (code=exited, status=0/SUCCESS)
Main PID: 17724 (code=exited, status=0/SUCCESS)

Do you have any idea where can be the problem?

Thanks in advance

Re: OpenVPN does not listen (on any port)

Posted: Sat Sep 01, 2018 3:03 pm
by TinCanTech
Do not start openvpn with systemd until you have a correct service file.

Instead, start it like so:

Code: Select all

$ sudo openvpn --config /path/to/server.conf

Re: OpenVPN does not listen (on any port)

Posted: Sat Sep 01, 2018 5:00 pm
by julo
You are right, different config file was used by openvpn than the one I edited. Thanks!