Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations John Tel on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

DNS server and host file

Status
Not open for further replies.

juniper911

Technical User
Mar 7, 2007
181
GB
Hi all

I wanted to know if this would work, on a windows 2000 SP4 DNS server, if I added an entry to the host file for a particular site with a IP address. Would that then stop the DNS server going out on the Internet in trying to resolve the name because it would look up its own host file first? Or will it still go out to resolve it?

thanks
 
I think i have seen that as a working solution but why not add an A record with that address to the DNS server so it knows the IP of the host?
 
My DNS server is not authorative for that domain, the problem with this other site is that their DNS servers do not hand out the A record correctly or all the time.

I can see the A records for that site only when I clear the cache on my own DNS servers.

I think the other alternative is for me to create a forward lookup zone for that particular site and domain but i dont want to take that route.
 
Juniper911...
Yes it will work, as the hosts file information is used before recursion.
An example, the Spybot program adds entries to the hosts file, (if the option is chosen), to block malware/spam/virus/porn etc sites, with an IP entry of 127.0.0.1 to block bad site.

Porkchopexpress has a good point.. if it is a "good" site, would be better to add the entry to DNS, as it is easier for other techs to see what is happening.

........................................
Chernobyl disaster..a must see pictorial
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top