Quote:
Originally Posted by 7
I don't know how the OS processes the host file. I don't know if it is all cached or read for each request. I assume cached somehow. But 450kb is manageable.
You might see a slowdown when you hit 450MB though
How many lines is 450kb of entries?
|
So it should only get referenced when somebody wants to open a socket to somewhere else. But you don't have to restart anything when you edit the hosts file for your changes to take effect, so when you do that lookup it must parse the file every time.
That said, that file would have to get "pretty darn big" for parsing it to take longer (real-time-wise) than a dns request...but if the host ISN'T in your hosts file, it has to walk the whole file before it sends out the dns request, so
that may be a noticeable delay, especially if you've got something running that tends to spam a lot of dns lookups. Also, the CPU isn't busy while waiting for a dns response, but is busy while parsing the hosts file.