Re: [squid-users] good intro on the role of /etc/hosts with relation to cache_peer's?

From: Henrik Nordstrom <henrik@dont-contact.us>
Date: Tue, 12 Jun 2007 00:27:11 +0200

mån 2007-06-11 klockan 18:23 +0200 skrev Anton Melser:
> Hi,
> I have realised my problem... I was trying to switch machines with a
> site, but had forgotten to change /etc/hosts. Is this the perfect
> example of the difference between compiling with and without the
> internal dns option?

No, both uses /etc/hosts first..

> I ask this because no matter what IP address I
> put in the cache_peer, it still seems to look at /etc/hosts...

That's because you have told Squid to completely ignore your cache_peers
by enabling always_direct, forcing Squid to go directly to the requested
site instead of forwarding it via the peers.

You do not need to define any hosts in /etc/hosts, unless you need these
in the host part of your cache_peer lines to keep your configuration
readable.. (the cache_peer host can be specified either by IP or name..)

Regards
Henrik

Received on Mon Jun 11 2007 - 16:27:20 MDT

This archive was generated by hypermail pre-2.1.9 : Sun Jul 01 2007 - 12:00:04 MDT