Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

A friend of mine setup a VPN to connect to his server using openvpn. I installed "network-manager-openvpn" (I'm in ubuntu) and I created a new VPN connection using the certificates he sent me. The VPN connected successfully but when I tried to load any pages the connection would just timeout. He then sent me this configuration file:

port 1194
proto udp
dev tun
dev-type tun
ns-cert-type server
reneg-sec 86400
auth-retry interact
comp-lzo yes
verb 3
ca ca.crt
cert andrew-1.crt
key andrew-1.key

Which is apparently an exact copy of his configuration he used on his mac where he was able to connect and work successfully with the VPN.

So I imported that file to create a new VPN and I was still having the same issue. When I ran "netstat -nr" I got the following output:

Destination     Gateway         Genmask         Flags   MSS Window  irtt Iface         UG        0 0          0 tun0 UGH       0 0          0 tun0 UH        0 0          0 tun0     U         0 0          0 tun0 UGH       0 0          0 wlan0   U         0 0          0 wlan0

I feel as if maybe there is too many things being routed through the VPN. My friend and I tried troubleshooting but I'm not very knowledgeable with OpenVPN I've only used PPTP where I just put the IP and my credentials and I'm good to go. Maybe someone may know if I'm supposed to configure something specifically that I haven't? All I've done is install network-manager-openvpn and imported that file to create a new VPN (and entered credentials) and nothing else.

share|improve this question
up vote 1 down vote accepted

The first line of your "netstat -nr" is sending all traffic out the VPN (Except the VPN endpoint and local traffic). You need to stop that route from being added to your VPN, and that will most likely solve your problem.

You may well find that it is your friends configuration (ie the server) which is pushing this default route and causing the problems (maybe he has "redirect-gateway" or configured his system to push a default gateway - it does not appear to be your config).

You can temporarily (until the tunnel is restarted) test this theory by deleting the default route. Try

route del default gw
route add default gw
share|improve this answer
Ran those two lines and everything is working perfectly! Definitely a workaround while I figure out why this is happening and how to stop it. – General Kandalaft Feb 16 '13 at 2:18
Its not you, its your friend. You should ask him to stop pushing a default gateway via your OpenVPN setup. In the interim, you can add "route-nopull" in your config to ignore the gateway he is pushing, (Oh, and can you accept the answer ?) – davidgo Feb 16 '13 at 5:45

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .