My desktop is part of the company domain and receives its IP address and DNS search list via DHCP. That's fine, of course. Is there a way that I can append additional entries to the end of the DNS search list that I got via DHCP?
When I bring up the NIC adapter settings for TCP/IP v4, of course it is set to obtain IP address and DNS server address automatically. Opening "Advanced" and clicking on the DNS tab, the DNS search list configuration is greyed out.
Is there a command or script I can run each time I boot to append to the end of the DNS search list that I get via DHCP?
My goal is to avoid having to type out long fully-qualified names for additional domains I frequently access (in our labs) that the company doesn't want to add to the DNS search list that everyone gets via DHCP.
Edit: In Linux, the configuration to do what I am looking for is easy. You configure either the DHCP client or the network interface itself to append or prepend or supersede the search list you get via DHCP. For an example of how to do in Linux what I am trying to do in Windows, see https://superuser.com/a/264032/2505 or http://jurjenbokma.com/ApprenticesNotes/domain_search_override.html
Does the lack of answers mean that this trivial configuration in Linux is not possible in Windows 7?
I found a way to do this which is probably a workaround and which won't work on a locked-down box where you don't have admin rights. Edit the registry key:
Add to the end of that key any domains you want to add to your search list -- although this key may entirely replace your search list. This list should be comma-separated with no whitespace.
After making the change, you have to renew your DHCP lease as a way of getting the DHCP client to run so you can apply the change:
Once you have done this, you'll have the new entries in your DNS search list.
While I'm not sure how Group Policy will interact with this, you can manually edit the registry value
HKLM\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters\SearchList
to contain a comma separated (no spaces!) list of domain name suffixes that get appended to your DNS.You can't append to the list provided by DHCP as far as I know.
Instead of setting your DNS to automatic, set it to manual and put in your primary DNS servers. Then you can input as many DNS servers as you want.
You'll probably want to change your suffix behaviour so it looks up the other domains too - this bit is probably more important in terms of helping you avoid typing FQDNs and instead just type hostnames.
Personally, the way I do this, is have my DNS servers setup with forwarders, i.e. they forward requests to other domains to get the answers and I simply put my suffix list in there, but my PC only queries my domain's DNS servers. I don't have to type FQDNs.
What are you trying to accomplish with the additional DNS? Are you trying to get to another resource? The answer is likely no, as workarounds like adding an entry to a host file, or creating a static route will be disabled if you are a standard user.
I stuck with this problem as I wanted to add some URLs in DNS box but it was not letting me do anything and the whole block was greyed out.
Also, did not get any further help from Googling. Ultimately tried some combination of guesses and fortunately one of them worked for me and it made the DNS block editable.
Here are the steps:
Now check you DNS block under Advanced TCP/IP configuration, it should be editable now.