Hi,

I'm running Squid 2.6 STABLE12 as a reverse proxy. It is configured to select one of two origin servers based on the request URL like this:

cache_peer 10.1.64.104 parent 8102 0 originserver no-query round-robin
cache_peer 10.1.64.106 parent 8105 0 originserver no-query round-robin

# always_direct = default
never_direct allow all

acl api_url urlpath_regex ^/api/*

cache_peer_access 10.1.64.104 allow api_url
cache_peer_access 10.1.64.104 deny all
cache_peer_access 10.1.64.106 allow !api_url
cache_peer_access 10.1.64.106 deny all

Currently only URLs that *do* match the api_url acl are ever sent to Squid.

After a power outage yesterday I started seeing "X-Squid-Error: ERR_CANNOT_FORWARD 11" in the response headers of some but not all such requests. I had no difficulty connecting directly to the origin server at 10.1.64.104:8102. The errors went away as soon as I restarted Squid.

This raises the following questions:

1) Is it inappropriate to use the 'round-robin' option in this way, since only one origin server peer will match the cache_peer_access rules for a given URL?

2) Why did some requests succeed and some fail? Is there a health test that blocks the opening of new connections but allows existing persistent connections to be reused?

Does anyone have insight on these?

Thanks,
Ben

Reply via email to