OpenVPN - I can't connect

This is used for general discussion that is not necessarily server-related.
User avatar
ErikIvaN
A semi-regular
A semi-regular
Posts: 16
https://www.youtube.com/channel/UC40BgXanDqOYoVCYFDSTfHA
Joined: Tue Dec 09, 2014 10:17 am
Contact:

OpenVPN - I can't connect

Post by ErikIvaN »

Install openvpn I saw on the forum but it gives me error when connecting, anyone can help me install or otherwise fix the error. It is ubuntu 14.04.01 Lts, sorry I'm not good for English :? :?:
User avatar
soja
This is my homepage
This is my homepage
Posts: 2389
Joined: Fri May 18, 2012 3:20 pm

Re: OpenVPN - I can't connect

Post by soja »

Can you provide the specific error you are getting when trying to connect?

Have you confirmed the openvpn process is running, and listening on the correct port?
Not a NFO employee
User avatar
ErikIvaN
A semi-regular
A semi-regular
Posts: 16
Joined: Tue Dec 09, 2014 10:17 am
Contact:

Re: OpenVPN - I can't connect

Post by ErikIvaN »

162.248.88.85:1164

Error 868 No se realizó la conexión remota porque no se resolvió el nombre del servidor de acceso remoto.
User avatar
soja
This is my homepage
This is my homepage
Posts: 2389
Joined: Fri May 18, 2012 3:20 pm

Re: OpenVPN - I can't connect

Post by soja »

This tool reports that the port you are using is closed: http://www.yougetsignal.com/tools/open-ports/

Are you using windows or linux? Have you confirmed that the process is actually running, and not restricted by any firewall?
Not a NFO employee
User avatar
ErikIvaN
A semi-regular
A semi-regular
Posts: 16
Joined: Tue Dec 09, 2014 10:17 am
Contact:

Re: OpenVPN - I can't connect

Post by ErikIvaN »

root@fastwolf:~# sudo ufw disable
Firewall stopped and disabled on system startup
root@fastwolf:~# restart openvpn
restart: Unknown job: openvpn
root@fastwolf:~# /etc/init.d/openvpn restart
* Stopping virtual private network daemon(s)... * Stopping VPN 'server' [ OK ]
* Starting virtual private network daemon(s)... * Autostarting VPN 'server' root@fastwolf:~# nc -zv 162.248.88.85
This is nc from the netcat-openbsd package. An alternative nc is available
in the netcat-traditional package.
usage: nc [-46bCDdhjklnrStUuvZz] [-I length] [-i interval] [-O length]
[-P proxy_username] [-p source_port] [-q seconds] [-s source]
[-T toskeyword] [-V rtable] [-w timeout] [-X proxy_protocol]
[-x proxy_address[:port]] [destination] [port]
root@fastwolf:~# nc -zv 162.248.88.85 1164
nc: connect to 162.248.88.85 port 1164 (tcp) failed: Connection refused
root@fastwolf:~# ^C
User avatar
soja
This is my homepage
This is my homepage
Posts: 2389
Joined: Fri May 18, 2012 3:20 pm

Re: OpenVPN - I can't connect

Post by soja »

While OpenVPN is running, try running this command:

netstat -lp | grep 1164

It should return the PID of openvpn to confirm that the process is running and listning on the correct port.

If not, check any logs that openVPN creates for potential errors.
Not a NFO employee
User avatar
ErikIvaN
A semi-regular
A semi-regular
Posts: 16
Joined: Tue Dec 09, 2014 10:17 am
Contact:

Re: OpenVPN - I can't connect

Post by ErikIvaN »

server' root@fastwolf:~# netstat -lp | grep 1164
-bash: syntax error near unexpected token `('

:? and where I find the logs :?:
User avatar
ErikIvaN
A semi-regular
A semi-regular
Posts: 16
Joined: Tue Dec 09, 2014 10:17 am
Contact:

Re: OpenVPN - I can't connect

Post by ErikIvaN »

root@fastwolf:~# netstat -lp | grep 1164
root@fastwolf:~# nc -zv 162.248.88.85 1164
nc: connect to 162.248.88.85 port 1164 (tcp) failed: Connection refused
root@fastwolf:~#
User avatar
soja
This is my homepage
This is my homepage
Posts: 2389
Joined: Fri May 18, 2012 3:20 pm

Re: OpenVPN - I can't connect

Post by soja »

hm are you sure you are typing the netstat command in correctly? This is what I am shown when doing it on my linux VDS for the port my COD4 server is on:

Image
Not a NFO employee
User avatar
ErikIvaN
A semi-regular
A semi-regular
Posts: 16
Joined: Tue Dec 09, 2014 10:17 am
Contact:

Re: OpenVPN - I can't connect

Post by ErikIvaN »

Yes im sure the command is correct
User avatar
ErikIvaN
A semi-regular
A semi-regular
Posts: 16
Joined: Tue Dec 09, 2014 10:17 am
Contact:

Re: OpenVPN - I can't connect

Post by ErikIvaN »

root@fastwolf:~#: command not found
root@fastwolf:~# netstat -lp | grep 1164
root@fastwolf:~# netstat -lp | grep 28960
root@fastwolf:~# -

:? Port 1164 is closed on 162.248.88.85.
User avatar
soja
This is my homepage
This is my homepage
Posts: 2389
Joined: Fri May 18, 2012 3:20 pm

Re: OpenVPN - I can't connect

Post by soja »

Check for any logs OpenVPN generates(I am not sure where they would be, or if you have to enable them through configs, I have never used it), and look for errors.

Confirm the process is running using:

ps aux | grep vpn (this should work if the process name is openvpn).

If you don't see a resulting line here, the process isn't running.
Not a NFO employee
User avatar
ErikIvaN
A semi-regular
A semi-regular
Posts: 16
Joined: Tue Dec 09, 2014 10:17 am
Contact:

Re: OpenVPN - I can't connect

Post by ErikIvaN »

soja wrote:Check for any logs OpenVPN generates(I am not sure where they would be, or if you have to enable them through configs, I have never used it), and look for errors.

Confirm the process is running using:

ps aux | grep vpn (this should work if the process name is openvpn).

If you don't see a resulting line here, the process isn't running.
root@fastwolf:~# ps aux | grep vpn
root 10459 0.2 0.3 24208 6188 ? Ss 09:50 0:02 /usr/sbin/openvpn --writepid /run/openvpn/server.pid --daemon ovpn-server --cd /etc/openvpn --config /etc/openvpn/server.conf --script-security 2
root 10758 0.0 0.0 11744 916 pts/4 S+ 10:11 0:00 grep --color=auto vpn
root@fastwolf:~#

I can't find the logs
User avatar
Edge100x
Founder
Founder
Posts: 13113
Joined: Thu Apr 18, 2002 11:04 pm
Location: Seattle
Contact:

Re: OpenVPN - I can't connect

Post by Edge100x »

You'll need a firewall running for it to work right.

I really recommend running the install script mentioned in http://www.nfoservers.com/forums/viewto ... 46&t=11034, as it does everything for you.
User avatar
ErikIvaN
A semi-regular
A semi-regular
Posts: 16
Joined: Tue Dec 09, 2014 10:17 am
Contact:

Re: OpenVPN - I can't connect

Post by ErikIvaN »

Edge100x wrote:You'll need a firewall running for it to work right.

I really recommend running the install script mentioned in http://www.nfoservers.com/forums/viewto ... 46&t=11034, as it does everything for you.
Wait
Post Reply