2
I'm using Ubuntu 12.04 LTS. I use a VPN for work. In network manager, for both my normal wired connection, and for the VPN connection also, I have it configured to "Automatic (VPN) addresses only" and I specify the nameservers I want to use. But when I view /etc/resolv.conf after connecting to the VPN, it shows different nameservers. Even after disconnecting from the VPN, it's using those nameservers that I did not specify.
The problem is this causes a large delay in browsing the web because the VPN nameservers are either really slow or maybe it's timing out.
How can I get it to stick to using the nameservers I specify?
If I edit resolv.conf and set it to the nameservers I want, the delay goes away, so I know this is the problem. But every time I use connect to the VPN, it just overwrites it again.
I'm reading through all that and trying various things but it still is automatically injecting 2 nameservers in resolv.conf whenever I connect to the VPN. I gave up and just made /etc/resolv.conf a regular file. – mentics – 2012-07-06T11:19:16.760
If you want to add more entries to
/etc/resolv.conf
, create a/etc/resolvconf/resolv.conf.d/tail
and add them there, BUT If/etc/resolv.conf
contains127.0.0.1
, then adding entries to/etc/resolvconf/resolv.conf.d/tail
won't really do anything useful. You should instead set the list of DNS servers statically in Network Manager which will then be configured indnsmasq
(that's running on 127.0.0.1). – atenz – 2012-07-06T11:27:09.883127.0.0.1 does show up. As I explained in my question, I did specify static DNS servers in Network Manager. But it appears to be ignoring them. – mentics – 2012-07-08T06:47:02.240
I would really suggest asking this question in Ask Ubuntu .I believe you will get better answer there , since Ubuntu related. Please unaccept this answer , since it doesn't solves your problem. Thank you. – atenz – 2012-07-08T07:39:52.953
Your answer led me to a solution, so I'll leave it accepted. Your reference to the question on Ask Ubuntu has very useful information. – mentics – 2012-07-09T17:54:33.387