stopping domain-name-servers on DHCPv4

Dave Woyciesjes woyciesjes at
Mon Sep 12 21:34:43 UTC 2011

Karl Auer wrote:
> On Sat, 2011-09-10 at 08:29 +0200, Nils Kassube wrote: 
>> Karl Auer wrote:
>>> I want DHCPv4 to get me an address, but I do NOT want it to write the
>>> received nameserver addresses into resolv.conf. DHCP is being done by
>>> wicd.
>>> I've already tried several things:
>> ... which all included mangling of conf files. At the properties 
>> dialogue for the connection you can set static DNS servers while still 
>> using DHCP to get the address. But I never tried that myself, so I'm not 
>> sure if it really works.
> Thanks Nils. I don't want a static DNS address.
> However, your answer gave me the idea that perhaps if I checked the
> "Static DNS" flag in wicd, without actually supplying nameserver
> addresses, wicd would do some magic to stop DHCP writing nameserver info
> into resolv.conf. Sadly this did not happen - wicd let me check the box,
> but it didn't "stick" unless I supplied actual nameserver info.

	Out of my depth a bit here, but wouldn't supplying as the 
nameserver be the same as leaving it empty?

> What I want is for DHCP to NOT write into resolv.conf any nameserver
> addresses it receives. It *should* write any search names etc, and it
> should acquire addresses for interfaces.
> I'd be happy with a solution that prevented the server sending me
> nameserver addresses, or a solution that caused the DHCP client to
> ignore them, or a solution that simply prevented them being written into
> resolv.conf. It's got to the point where I'm seriously considering
> adding my own post-connection script to run after resolv.conf and rip
> out nameserver lines, but that seems somehow antisocial :-) 
> Regards, K.

--- Dave Woyciesjes
--- ICQ# 905818
--- AIM - woyciesjes
--- CompTIA A+ Certified IT Tech -
--- HDI Certified Support Center Analyst -
             Registered Linux user number 464583

"Computers have lots of memory but no imagination."
"The problem with troubleshooting is that trouble shoots back."
  - from some guy in the internet.

More information about the ubuntu-users mailing list