dhclient the right way(tm)

This is not exactly complicated but I feel the need to document this before I forget. Say you have a machine facing a hostile DHCP server (the type which is very aggressive with lease times). The problem here is that you need a long list of DNS and search to your resolv.conf. There are many ways to tackle this including the axe. On Debian, the clean and elegant way is to edit /etc/dhclient/dhclient.conf and uncomment these two lines:

supersede domain-search "domain.com", "another.domain.com", "etc.domain.com";
prepend domain-name-servers 127.0.0.1;

Note here that i am pre-pending my own DNS because it is nicer to use your own resolver rather than rely on someone else’s.