Squid_ The Definitive Guide - Duane Wessels [179]
cache_peer medcache.isp.net sibling 3128 4827 htcp
cache_peer 172.16.45.111 parent 3128 0 no-query default
Related
cache_peer_access, http_port, icp_port, htcp_port, icp_query_timeout, dead_peer_timeout, peer_connect_timeout, cache_peer_domain, neighbor_type_domain
Name
cache_peer_domain
Synopsis
This directive allows you to restrict forwarded requests by their domain names. For example, you can make sure that URIs in a certain domain never go to your parent cache. Similarly, you can make sure that requests for only a few specific domain names are sent to a neighbor. The cache_peer_domain directive has been largely superseded by cache_peer_access, which is much more flexible.
Following the neighbor's hostname, you can specify a list of domain names. These are searched in order, until Squid finds a match. A match means that the request can be sent to the neighbor, unless you prefix the domain name with ! ("not"). For example, .foo.com means "allow .foo.com," while !.bar.net means "disallow .bar.net." If none of the listed domains match the URL, the default action (allow or deny) is the opposite of the last one in the list.
Note, the domain name matching algorithm is somewhat tricky. See the description in Section 6.1.1.2.
Syntax
cache_peer_domain hostname
domain ...
Default
No default
Example
cache_peer_domain bigcache.isp.net .net .org
cache_peer_domain aol.web-cache.net !.ads.aol.com .aol.com
Related
cache_peer, cache_peer_access, neighbor_type_domain
Name
neighbor_type_domain
Synopsis
You can use this directive to modify the relationship for a neighbor cache selectively. For example, you may have a sibling neighbor that allows you to fetch misses for certain, nearby domains. The neighbor_type_domain option overrides the type given in the cache_peer line for requests that match the listed domains.
The syntax and algorithms for matching domain names are identical to the cache_peer_domain directive.
Syntax
neighbor_type_domain parent|sibling hostname
domain ...
Default
No default
Example
neighbor_type_domain bigcache.isp.net parent .customer.isp.net
Related
cache_peer, cache_peer_domain
Name
icp_query_timeout
Synopsis
When Squid sends an ICP/HTCP query to one or more neighbors, it waits some amount of time for the replies to arrive. Because the messages are unreliable UDP datagrams, the queries and/or replies may never arrive. Squid automatically figures out how long to wait for ICP/HTCP replies. For a particular query, the timeout is twice the mean of how long it took for recent replies to arrive. In other words, Squid averages the query RTT values from previous requests, doubles it, and waits that amount of time. This algorithm works best when all your neighbors have about the same RTT, and when network conditions are consistent.
You can override this algorithm with the icp_query_timeout directive. Instead of dynamically calculating the timeout, Squid waits a fixed amount of time for every ICP/HTCP query.
Syntax
icp_query_timeout milliseconds
Default
No default
Example
icp_query_timeout 1500
Related
icp_port, htcp_port, maximum_icp_query_timeout, mcast_icp_query_timeout, dead_peer_timeout
Name
maximum_icp_query_timeout
Synopsis
I described Squid's dynamic ICP/HTCP timeout algorithm under icp_query_timeout . If you'd like to use that algorithm, but wish to place an upper limit on the timeout, use the maximum_icp_query_timeout directive instead. Rather than a fixed timeout, Squid uses the dynamic timeout but makes sure it doesn't exceed the limit that you specify.
Syntax
maximum_icp_query_timeout milliseconds
Default
No default
Example
maximum_icp_query_timeout 3000
Related
icp_port, htcp_port, icp_query_timeout
Name
mcast_icp_query_timeout
Synopsis
When you use multicast ICP, Squid doesn't know in advance how many multicast-capable neighbors are listening for its messages. Squid determines this by sending periodic probes to the multicast group and counting the