OpenConnect does not revert DNS after disconnecting from VPN

Jędrek Domański jedrek.domanski at gmail.com
Fri Nov 13 05:40:46 EST 2020


Hello,
I am using OpenConnect on Ubuntu 16.04 to connect to my client's IT
infrustructure and am having problems after disconnecting VPN. Prior
connecting to VPN my /etc/resolv.conf looks like this:

nameserver 127.0.1.1
search home

After connecting to VPN my /etc/resolv.conf gets changed and I get
nameserver and search from my client's server configuration, which is
fine, however after disconnecting VPN my /etc/resolv.conf stays the
same and my internet connection speed is dramatically degraded and it
takes almost 10 seconds for every page to load. I have checked my
network configuration and have confirmed with my ISP provider that the
correct DNS servers are provided for me and that the issue comes from
openconnect not reverting the changed configuration file
/etc/resolv.conf. The nameserver I am left off with is the Google DNS
8.8.8.8 which I get from my client's server, because they might be
using it inside of their infrastructure for some reason. I've tried it
on my Mac and after disconnecting VPN /etc/resolv.conf is reverted to
what it was prior establishing the connection. This should also happen
on Linux but it does not. Why does this not happen and how do I fix
this?

Jędrzej



More information about the openconnect-devel mailing list