On 12/06/07, Henrik Nordstrom <[EMAIL PROTECTED]> wrote:
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..)
Thanks Hendrik, everything seems much clearer now! I got really
confused trying to put my file together not really knowing how things
worked and getting bits from various 2.6 and pre 2.6 examples. It is
working like a charm now though!
Cheers
Anton