OpenVPN locks me out of internet

Hey there folks!

I installed manjaro in this computer of my new job, as I’m very used to it, however I’m stuck at trying to make OpenVPN work. This was my second time with a vpn in manjaro. I installed networkmanager-openvpn to add its functionality to nm and then added the config file my company sent me via the import from file button in the gui (I also tried via cli with nmcli) and wrote my login+password as well. Then I connected to the VPN and it did connect without errors. The issue is that after this I’m unable to load any website and/or find any hosts. For example:

  • witthout VPN:
$ ping www.google.com
PING www.google.com (142.250.74.36) 56(84) bytes of data.
64 bytes from arn09s22-in-f4.1e100.net (142.250.74.36): icmp_seq=1 ttl=111 time=218 ms
  • with VPN:
$ ping www.google.com
ping: www.google.com: No address associated with hostname

There is no error log nor anything else I can think of. Do I have to set something else up? Obs: this was all made on a fresh install.

Edit: I noticed that I am able to access only private company websites/systems using the VPN, but nothing external. This is good, but still an issue, as I have to turn the VPN on/off a lot. Given this behavior, is this some fault on my end or only the setup of the VPN? I’m trying to see if this was intended, but seems unlikely to me.

Is it DNS? No, it can’t be DNS. It was DNS.

Can you look at the /etc/resolve.conf file after connecting?

ping 8.8.8.8. to check that your connection is working but DNS isn’t:

Well, ping 8.8.8.8 worked equally well with and without the VPN, so I think you are correct. But what should I do to properly configure the DNS? Also, cat /etc/resolv.conf gave

# Generated by NetworkManager
search konzept-is.de
nameserver 172.xx.xx.1
nameserver 181.xxx.xxx.2
nameserver 181.xxx.xxx.3
# NOTE: the libc resolver may not support more than 3 nameservers.
# The nameservers listed below may not be recognized.
nameserver 2804:14d:1:0:xxx:xxx:xxx:2
nameserver 2804:14d:1:0:xxx:xxx:xxx:3

(xxx added my me)

What is this VPN used for? Only to access company?

If so, did you check the “Use only for resources on this connection” checkbox under Settings –> IPv4/6 –> Routes?

Yep, the VPN is only for the company’s systems. Nope, I don’t even see this box you are saying, as there is no Routes. All I have is

It’s right there in the picture, above Apply.

LOL, yeah, I’m sorry. I just checked the boxes and tested, but it didn’t change the behavior. ping still does not find google.

Reconnect VPN. Also can you post

ip route

Results of ip routeare below.

  • without VPN:
default via 192.168.0.1 dev wlp0s20f3 proto dhcp src 192.168.0.28 metric 20600 
192.168.0.0/24 dev wlp0s20f3 proto kernel scope link src 192.168.0.28 metric 600
  • with VPN:
default via 192.168.0.1 dev wlp0s20f3 proto dhcp src 192.168.0.28 metric 600 
10.10.10.0/24 via 10.10.10.206 dev tun0 proto static metric 50 
10.10.10.206 dev tun0 proto kernel scope link src 10.10.10.205 metric 50 
172.16.0.0/12 via 10.10.10.206 dev tun0 proto static metric 50 
192.168.0.0/24 dev wlp0s20f3 proto kernel scope link src 192.168.0.28 metric 600 
192.168.0.1 dev wlp0s20f3 proto static scope link metric 50 
192.168.3.0/24 via 10.10.10.206 dev tun0 proto static metric 50 
212.xx.xxx.222 via 192.168.0.1 dev wlp0s20f3 proto static metric 50

Man, I just searched more about dns and finally understood the issue. Thanks for the nudge in the right direction. For anyone wondering in the future, I just wen to ipv4 under the VPN settings and added 8.8.8.8 (google) to the DNS servers list and all worked.

Make sure company policy allows you to do this…

It seems that if your company allows you to use a VPN over the internet, this shouldn’t be a problem. It appears as though the issue might be related to incorrectly routed DNS server addresses. Since OP obscured the DNS server addresses provided by OpenVPN, it’s uncertain whether this assessment is correct.

This topic was automatically closed 36 hours after the last reply. New replies are no longer allowed.