VPN not working

I’m trying to create an OpenVPN server with my raspberry pi, and when I connect using OpenVPN GUI on my computer, I get
Sun Aug 14 19:53:02 2016 TLS Error: TLS key negotiation failed to occur within 60 seconds (check your network connectivity) Sun Aug 14 19:53:02 2016 TLS Error: TLS handshake failed

Please help me.

To be honest I think you might be better off on openvpn specific forums as this is not really a OSMC topic.

Anyhow if you want help you need to provide much more information like:

  1. Which steps have you done sofar?
  2. Your server configuration
  3. Your client configuration
  4. Log file from your server (you can configure the location of the log file in the config file)
  5. How is your network setup? are you using NAT or are you trying on your LAN?

TLS key negotiation failed to occur within 60 seconds (check your network connectivity)

This is a very general error that basically indicates a basic communication issue

Will I be better off just getting rid of everything that I did for vpn and start over? If yes, I need instructions on how to reinstall whatever sudo apt-get install -y openvpn easy-rsa installed, if it’s okay to delete some scripts I made, if it’s okay to delete the easy-rsa folder, and how to reset iptables.

I’ll also need accurate instructions on how to setup openvpn on a Debian server and a Windows 10 client. It’ll be easier on me if I undid everything.

(I have Teamviewer if you want to look at how messed up everything is through SSH or VNC)

Well I don’t think you need to uninstall/reinstall anything. Openvpn is relative straight forward (single config file and some keys). You can start from scratch with an empty key folder in easy-rsa if you want to.

In terms of instructions the openvpn pages are quite well written with good examples:

So I just do cd /etc/openvpn/easy-rsa, and do source ./vars and ./clean-all, and then delete the scripts I made? How do I reset and use iptables, because that might be messed up too.

iptables --flush

Thank you. I will try again. If it doesn’t work, I’ll tell you.

Hi TetrisSmasher,

You can find a detailed guide on how to set up OpenVPN on OSMC here


If you look at the end of the article there are links to the other 3 posts in his series including a very good guide on how to troubleshoot what may not work.

I followed it to the letter and it works flawlessly for me.