stopping domain-name-servers on DHCPv4

Karl Auer kauer at
Sat Sep 10 05:38:24 UTC 2011

I have an oddball problem.

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

I've already tried several things:

- editing /etc/dhcp3/dhclient.conf in various ways, before realising
  that wicd was managing DHCPv4 with it's own config file :-)

- using the supersede keyword in /etc/wicd/dhclient.conf.template

  The new line appears as expected in /var/lib/wicd/dhclient.conf,
  but the nameservers from the DHCPv4 server still appear in
  resolv.conf. I've tried an empty nameserver address (""), an IPv6
  address, and an IPv4 address.

- adding a modified request line to /etc/wicd/dhclient.conf.template

  The new set of requested items, minus the domain-name-servers item,
  appears in /var/lib/wicd/dhclient.conf as expected, but the
  nameservers from the DHCPv4 server still appear in resolv.conf. I.e.,
  the server is sending them even though the client is not requesting
  them, I guess.

I thnk resolvconf is interfering, but I can't see an easy way to tell
resolvconf how to behave. The script
in /etc/dhcp3/dhclient-enter-hooks.d seems pretty simpleminded. I
disabled it, but the supersede line in wicd still had no effect.

Basically I'm not too sure what's actually going on. Any clues
gratefully received.

Regards, K.

Karl Auer (kauer at                   +61-2-64957160 (h)                   +61-428-957160 (mob)

GPG fingerprint: DA41 51B1 1481 16E1 F7E2 B2E9 3007 14ED 5736 F687
Old fingerprint: B386 7819 B227 2961 8301 C5A9 2EBC 754B CD97 0156
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part
URL: <>

More information about the ubuntu-users mailing list