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
PING ( 56(84) bytes of data.
64 bytes from ( icmp_seq=1 ttl=111 time=218 ms
  • with VPN:
$ ping
ping: 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 to check that your connection is working but DNS isn’t:

Well, ping 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
nameserver 172.xx.xx.1
# 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 dev wlp0s20f3 proto dhcp src metric 20600 dev wlp0s20f3 proto kernel scope link src metric 600
  • with VPN:
default via dev wlp0s20f3 proto dhcp src metric 600 via dev tun0 proto static metric 50 dev tun0 proto kernel scope link src metric 50 via dev tun0 proto static metric 50 dev wlp0s20f3 proto kernel scope link src metric 600 dev wlp0s20f3 proto static scope link metric 50 via dev tun0 proto static metric 50 via 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 (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.