DNS problem when connecting to a corporate VPN

Questions about Wi-Fi and other network devices, file sharing, firewalls, connection sharing etc
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
witizer

DNS problem when connecting to a corporate VPN

Post by witizer »

Hello everybody.
I am running Linux Mint 18.3. I have the following problem: I successfully connect to a corporate VPN (Cisco vpn) but when this happens, I cannot load web pages as apparently the DNS addresses are not resolved correctly. Could you help me? thank you!
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
User avatar
greerd
Level 6
Level 6
Posts: 1060
Joined: Sat Jul 31, 2010 10:58 am
Location: Nova Scotia, Canada

Re: DNS problem when connecting to a corporate VPN

Post by greerd »

Hi witizer, welcome to the forum.

I would start by checking your nameservers.

Code: Select all

cat /etc/resolv.conf
You will probably have to change them to your corporate nameserver addresses.
witizer

Re: DNS problem when connecting to a corporate VPN

Post by witizer »

Hello greerd, thank you for your answer.
This is what I get before connecting to the VPN:

Code: Select all

# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
#     DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
nameserver 127.0.1.1
And this is what I get after connecting:

Code: Select all

# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
#     DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
nameserver 127.0.1.1
search xxxxxx
There is an extra line added presumeby by my company.
Last edited by witizer on Sun Sep 27, 2020 1:02 pm, edited 2 times in total.
User avatar
greerd
Level 6
Level 6
Posts: 1060
Joined: Sat Jul 31, 2010 10:58 am
Location: Nova Scotia, Canada

Re: DNS problem when connecting to a corporate VPN

Post by greerd »

Your output from /etc/resolv.conf says you're using resolvconf (not to be mistaken for the text configuration file /etc/resolv.conf) and the nameserver 127.0.1.1 indicates that you're also using dnsmasq. As opposed to using a static /etc/resolv.conf file like I use, your /etc/resolv.conf should be a system link to /run/NetworkManager/resolv.conf.

Unfortunately I'm not familiar with dnsmasq so can only give a link or two that might help, also opening a terminal and entering man dnsmasq and man resolvconf will display the manual for said commands.

What I would try first is to add your corporate supplied dns nameserver addresses to your Network Manager - Edit Connections - Connection type (wired or wireless) - IPv4 Settings - DNS Servers, save and try that.

If no luck I might try following this link that disables dnsmasq and see if the newly edited Network Manager DNS server addresses now work.

Are you using Cisco AnyConnect for Linux app? If so maybe this link and the "Humans" link included might help.

Sorry I can't be more definitive, maybe someone else has more info,
Good Luck

EDIT: When I mention dnsmasq above, I should of been explicit and indicated you probably have dnsmasq-base installed, which is part of or can be used in conjunction with Network Manager. The first link above (disabling dnsmasq) only mentions dnsmasq but it is actually talking about dnsmasq-base.
witizer

Re: DNS problem when connecting to a corporate VPN

Post by witizer »

What I would try first is to add your corporate supplied dns nameserver addresses to your Network Manager - Edit Connections - Connection type (wired or wireless) - IPv4 Settings - DNS Servers, save and try that.
Solved using your first solution. Thank you a lot and Merry Christmas.
User avatar
greerd
Level 6
Level 6
Posts: 1060
Joined: Sat Jul 31, 2010 10:58 am
Location: Nova Scotia, Canada

Re: DNS problem when connecting to a corporate VPN

Post by greerd »

You're welcome, glad you got it sorted out.

Merry Christmas to you too!
Locked

Return to “Networking”