]>
Commit | Line | Data |
---|---|---|
3a278cb8 | 1 | |
9cef6668 | 2 | # |
5ff76111 | 3 | # $Id: cf.data.pre,v 1.210 2001/01/30 10:06:48 hno Exp $ |
9cef6668 | 4 | # |
5 | # | |
2b6662ba | 6 | # SQUID Web Proxy Cache http://www.squid-cache.org/ |
9cef6668 | 7 | # ---------------------------------------------------------- |
8 | # | |
2b6662ba | 9 | # Squid is the result of efforts by numerous individuals from |
10 | # the Internet community; see the CONTRIBUTORS file for full | |
11 | # details. Many organizations have provided support for Squid's | |
12 | # development; see the SPONSORS file for full details. Squid is | |
13 | # Copyrighted (C) 2000 by the Regents of the University of | |
14 | # California; see the COPYRIGHT file for full details. Squid | |
15 | # incorporates software developed and/or copyrighted by other | |
16 | # sources; see the CREDITS file for full details. | |
9cef6668 | 17 | # |
18 | # This program is free software; you can redistribute it and/or modify | |
19 | # it under the terms of the GNU General Public License as published by | |
20 | # the Free Software Foundation; either version 2 of the License, or | |
21 | # (at your option) any later version. | |
22 | # | |
23 | # This program is distributed in the hope that it will be useful, | |
24 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
25 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
26 | # GNU General Public License for more details. | |
27 | # | |
28 | # You should have received a copy of the GNU General Public License | |
29 | # along with this program; if not, write to the Free Software | |
30 | # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. | |
31 | # | |
32 | ||
0f74202c | 33 | COMMENT_START |
448cd7c7 | 34 | WELCOME TO SQUID 2 |
35 | ------------------ | |
3a278cb8 | 36 | |
cf5cc17e | 37 | This is the default Squid configuration file. You may wish |
2b6662ba | 38 | to look at the Squid home page (http://www.squid-cache.org/) |
6b8e7481 | 39 | for the FAQ and other documentation. |
3a278cb8 | 40 | |
debd9a31 | 41 | The default Squid config file shows what the defaults for |
42 | various options happen to be. If you don't need to change the | |
43 | default, you shouldn't uncomment the line. Doing so may cause | |
44 | run-time problems. In some cases "none" refers to no default | |
efd900cb | 45 | setting at all, while in other cases it refers to a valid |
debd9a31 | 46 | option - the comments for that keyword indicate if this is the |
47 | case. | |
48 | ||
0f74202c | 49 | COMMENT_END |
3a278cb8 | 50 | |
0f74202c | 51 | COMMENT_START |
3a278cb8 | 52 | NETWORK OPTIONS |
53 | ----------------------------------------------------------------------------- | |
0f74202c | 54 | COMMENT_END |
3a278cb8 | 55 | |
934b03fc | 56 | NAME: http_port ascii_port |
7e3ce7b9 | 57 | TYPE: sockaddr_in_list |
f53b06f9 | 58 | DEFAULT: none |
59 | DEFAULT_IF_NONE: 3128 | |
7e3ce7b9 | 60 | LOC: Config.Sockaddr.http |
934b03fc | 61 | DOC_START |
7e3ce7b9 | 62 | Usage: port |
63 | hostname:port | |
64 | 1.2.3.4:port | |
934b03fc | 65 | |
7e3ce7b9 | 66 | The socket addresses where Squid will listen for HTTP client |
67 | requests. You may specify multiple socket addresses. | |
68 | There are three forms: port alone, hostname with port, and | |
69 | IP address with port. If you specify a hostname or IP | |
70 | address, then Squid binds the socket to that specific | |
71 | address. This replaces the old 'tcp_incoming_address' | |
72 | option. Most likely, you do not need to bind to a specific | |
73 | address, so you can use the port number alone. | |
74 | ||
75 | The default port number is 3128. | |
76 | ||
efd900cb | 77 | If you are running Squid in accelerator mode, then you |
7e3ce7b9 | 78 | probably want to listen on port 80 also, or instead. |
79 | ||
80 | The -a command line option will override the *first* port | |
81 | number listed here. That option will NOT override an IP | |
82 | address, however. | |
934b03fc | 83 | |
efd900cb | 84 | You may specify multiple socket addresses on multiple lines. |
934b03fc | 85 | DOC_END |
86 | ||
87 | ||
88 | NAME: icp_port udp_port | |
89 | TYPE: ushort | |
90 | DEFAULT: 3130 | |
91 | LOC: Config.Port.icp | |
92 | DOC_START | |
78a0e865 | 93 | The port number where Squid sends and receives ICP queries to |
934b03fc | 94 | and from neighbor caches. Default is 3130. To disable use |
95 | "0". May be overridden with -u on the command line. | |
934b03fc | 96 | DOC_END |
97 | ||
459f1836 | 98 | NAME: htcp_port |
99 | IFDEF: USE_HTCP | |
100 | TYPE: ushort | |
101 | DEFAULT: 4827 | |
102 | LOC: Config.Port.htcp | |
103 | DOC_START | |
78a0e865 | 104 | The port number where Squid sends and receives HTCP queries to |
459f1836 | 105 | and from neighbor caches. Default is 4827. To disable use |
106 | "0". | |
107 | ||
6b8e7481 | 108 | To enable this option, you must use --enable-htcp with the |
109 | configure script. | |
459f1836 | 110 | DOC_END |
111 | ||
934b03fc | 112 | |
113 | NAME: mcast_groups | |
114 | TYPE: wordlist | |
115 | LOC: Config.mcast_group_list | |
1273d501 | 116 | DEFAULT: none |
934b03fc | 117 | DOC_START |
cf5cc17e | 118 | This tag specifies a list of multicast groups which your server |
78a0e865 | 119 | should join to receive multicasted ICP queries. |
934b03fc | 120 | |
121 | NOTE! Be very careful what you put here! Be sure you | |
122 | understand the difference between an ICP _query_ and an ICP | |
123 | _reply_. This option is to be set only if you want to RECEIVE | |
124 | multicast queries. Do NOT set this option to SEND multicast | |
a95856a0 | 125 | ICP (use cache_peer for that). ICP replies are always sent via |
934b03fc | 126 | unicast, so this option does not affect whether or not you will |
127 | receive replies from multicast group members. | |
128 | ||
129 | You must be very careful to NOT use a multicast address which | |
efd900cb | 130 | is already in use by another group of caches. |
934b03fc | 131 | |
cf5cc17e | 132 | If you are unsure about multicast, please read the Multicast |
2b6662ba | 133 | chapter in the Squid FAQ (http://www.squid-cache.org/FAQ/). |
cf5cc17e | 134 | |
934b03fc | 135 | Usage: mcast_groups 239.128.16.128 224.0.1.20 |
136 | ||
cf5cc17e | 137 | By default, Squid doesn't listen on any multicast groups. |
934b03fc | 138 | DOC_END |
139 | ||
140 | ||
934b03fc | 141 | NAME: tcp_outgoing_address outbound_address |
142 | TYPE: address | |
143 | LOC: Config.Addrs.tcp_outgoing | |
270b86af | 144 | DEFAULT: 255.255.255.255 |
934b03fc | 145 | DOC_NONE |
146 | ||
147 | NAME: udp_incoming_address | |
148 | TYPE: address | |
149 | LOC:Config.Addrs.udp_incoming | |
270b86af | 150 | DEFAULT: 0.0.0.0 |
934b03fc | 151 | DOC_NONE |
152 | ||
153 | NAME: udp_outgoing_address | |
154 | TYPE: address | |
155 | LOC: Config.Addrs.udp_outgoing | |
270b86af | 156 | DEFAULT: 255.255.255.255 |
934b03fc | 157 | DOC_START |
158 | Usage: tcp_incoming_address 10.20.30.40 | |
159 | udp_outgoing_address fully.qualified.domain.name | |
160 | ||
934b03fc | 161 | tcp_outgoing_address is used for connections made to remote |
162 | servers and other caches. | |
163 | udp_incoming_address is used for the ICP socket receiving packets | |
164 | from other caches. | |
165 | udp_outgoing_address is used for ICP packets sent out to other | |
166 | caches. | |
167 | ||
efd900cb | 168 | The default behavior is to not bind to any specific address. |
934b03fc | 169 | |
6b53c392 | 170 | A *_incoming_address value of 0.0.0.0 indicates that Squid should |
171 | listen on all available interfaces. | |
172 | ||
173 | If udp_outgoing_address is set to 255.255.255.255 (the default) | |
174 | then it will use the same socket as udp_incoming_address. Only | |
175 | change this if you want to have ICP queries sent using another | |
176 | address than where this Squid listens for ICP queries from other | |
177 | caches. | |
178 | ||
5a3f6538 | 179 | NOTE, udp_incoming_address and udp_outgoing_address can not |
6b53c392 | 180 | have the same value since they both use port 3130. |
934b03fc | 181 | |
7e3ce7b9 | 182 | NOTE, tcp_incoming_address has been removed. You can now |
183 | specify IP addresses on the 'http_port' line. | |
934b03fc | 184 | DOC_END |
185 | ||
0f74202c | 186 | COMMENT_START |
3a278cb8 | 187 | OPTIONS WHICH AFFECT THE NEIGHBOR SELECTION ALGORITHM |
188 | ----------------------------------------------------------------------------- | |
0f74202c | 189 | COMMENT_END |
934b03fc | 190 | |
40a1495e | 191 | NAME: cache_peer |
192 | TYPE: peer | |
1273d501 | 193 | DEFAULT: none |
0153d498 | 194 | LOC: Config.peers |
934b03fc | 195 | DOC_START |
196 | To specify other caches in a hierarchy, use the format: | |
197 | ||
6b53c392 | 198 | cache_peer hostname type http_port icp_port |
934b03fc | 199 | |
d0d41f07 | 200 | For example, |
934b03fc | 201 | |
202 | # proxy icp | |
203 | # hostname type port port options | |
204 | # -------------------- -------- ----- ----- ----------- | |
cf5cc17e | 205 | cache_peer parent.foo.net parent 3128 3130 [proxy-only] |
206 | cache_peer sib1.foo.net sibling 3128 3130 [proxy-only] | |
207 | cache_peer sib2.foo.net sibling 3128 3130 [proxy-only] | |
934b03fc | 208 | |
209 | type: either 'parent', 'sibling', or 'multicast'. | |
210 | ||
211 | proxy_port: The port number where the cache listens for proxy | |
212 | requests. | |
213 | ||
214 | icp_port: Used for querying neighbor caches about | |
215 | objects. To have a non-ICP neighbor | |
216 | specify '7' for the ICP port and make sure the | |
217 | neighbor machine has the UDP echo port | |
218 | enabled in its /etc/inetd.conf file. | |
219 | ||
220 | options: proxy-only | |
221 | weight=n | |
222 | ttl=n | |
223 | no-query | |
224 | default | |
225 | round-robin | |
226 | multicast-responder | |
b3264694 | 227 | closest-only |
46b034a4 | 228 | no-digest |
223213df | 229 | no-netdb-exchange |
95e36d02 | 230 | no-delay |
c3b33cb7 | 231 | login=user:password | PASS | *:password |
3f62decd | 232 | connect-timeout=nn |
7e3ce7b9 | 233 | digest-url=url |
987de783 | 234 | allow-miss |
934b03fc | 235 | |
236 | use 'proxy-only' to specify that objects fetched | |
237 | from this cache should not be saved locally. | |
238 | ||
239 | use 'weight=n' to specify a weighted parent. | |
240 | The weight must be an integer. The default weight | |
241 | is 1, larger weights are favored more. | |
242 | ||
243 | use 'ttl=n' to specify a IP multicast TTL to use | |
78a0e865 | 244 | when sending an ICP queries to this address. |
934b03fc | 245 | Only useful when sending to a multicast group. |
246 | Because we don't accept ICP replies from random | |
247 | hosts, you must configure other group members as | |
248 | peers with the 'multicast-responder' option below. | |
249 | ||
250 | use 'no-query' to NOT send ICP queries to this | |
251 | neighbor. | |
252 | ||
253 | use 'default' if this is a parent cache which can | |
254 | be used as a "last-resort." You should probably | |
255 | only use 'default' in situations where you cannot | |
256 | use ICP with your parent cache(s). | |
257 | ||
258 | use 'round-robin' to define a set of parents which | |
259 | should be used in a round-robin fashion in the | |
260 | absence of any ICP queries. | |
261 | ||
262 | 'multicast-responder' indicates that the named peer | |
263 | is a member of a multicast group. ICP queries will | |
264 | not be sent directly to the peer, but ICP replies | |
265 | will be accepted from it. | |
266 | ||
b3264694 | 267 | 'closest-only' indicates that, for ICP_OP_MISS |
268 | replies, we'll only forward CLOSEST_PARENT_MISSes | |
269 | and never FIRST_PARENT_MISSes. | |
270 | ||
46b034a4 | 271 | use 'no-digest' to NOT request cache digests from |
272 | this neighbor. | |
273 | ||
223213df | 274 | 'no-netdb-exchange' disables requesting ICMP |
275 | RTT database (NetDB) from the neighbor. | |
276 | ||
95e36d02 | 277 | use 'no-delay' to prevent access to this neighbor |
278 | from influencing the delay pools. | |
279 | ||
c68e9c6b | 280 | use 'login=user:password' if this is a personal/workgroup |
281 | proxy and your parent requires proxy authentication. | |
4472c779 | 282 | Note: The string can include URL escapes (i.e. %20 for |
283 | spaces). This also means that % must be written as %%. | |
c68e9c6b | 284 | |
94439e4e | 285 | use 'login=PASS' if users must authenticate against |
286 | the upstream proxy. Note: To combine this with | |
287 | proxy_auth both proxies must share the same user | |
288 | database as HTTP only allows for one proxy login. | |
289 | Also be warned that this will expose your users proxy | |
290 | password to the parent. USE WITH CAUTION | |
291 | ||
c3b33cb7 | 292 | use 'login=*:password' to pass the username to the |
293 | upstream cache, but with a fixed password. This is meant | |
294 | to be used when the peer is in another administrative | |
295 | domain, but it is still needed to identify each user. | |
296 | The star can optionally be followed by some extra | |
297 | information which is added to the username. This can | |
298 | be used to identify this proxy to the peer, similar to | |
299 | the login=username:password option above. | |
300 | ||
3f62decd | 301 | use 'connect-timeout=nn' to specify a peer |
302 | specific connect timeout (also see the | |
303 | peer_connect_timeout directive) | |
304 | ||
7e3ce7b9 | 305 | use 'digest-url=url' to tell Squid to fetch the cache |
306 | digest (if digests are enabled) for this host from | |
307 | the specified URL rather than the Squid default | |
308 | location. | |
3f62decd | 309 | |
987de783 | 310 | use 'allow-miss' to disable Squid's use of only-if-cached |
311 | when forwarding requests to siblings. This is primarily | |
312 | useful when icp_hit_stale is used by the sibling. To | |
313 | extensive use of this option may result in forwarding | |
314 | loops, and you should avoid having two-way peerings | |
315 | with this option. (for example to deny peer usage on | |
316 | requests from peer by denying cache_peer_access if the | |
317 | source is a peer) | |
318 | ||
934b03fc | 319 | NOTE: non-ICP neighbors must be specified as 'parent'. |
934b03fc | 320 | DOC_END |
321 | ||
af7d912e | 322 | NAME: cache_peer_domain cache_host_domain |
934b03fc | 323 | TYPE: hostdomain |
f1dc9b30 | 324 | DEFAULT: none |
325 | LOC: none | |
934b03fc | 326 | DOC_START |
cf5cc17e | 327 | Use to limit the domains for which a neighbor cache will be |
328 | queried. Usage: | |
934b03fc | 329 | |
af7d912e | 330 | cache_peer_domain cache-host domain [domain ...] |
331 | cache_peer_domain cache-host !domain | |
934b03fc | 332 | |
333 | For example, specifying | |
334 | ||
af7d912e | 335 | cache_peer_domain parent.foo.net .edu |
934b03fc | 336 | |
337 | has the effect such that UDP query packets are sent to | |
338 | 'bigserver' only when the requested object exists on a | |
339 | server in the .edu domain. Prefixing the domainname | |
340 | with '!' means that the cache will be queried for objects | |
341 | NOT in that domain. | |
342 | ||
343 | NOTE: * Any number of domains may be given for a cache-host, | |
344 | either on the same or separate lines. | |
345 | * When multiple domains are given for a particular | |
346 | cache-host, the first matched domain is applied. | |
347 | * Cache hosts with no domain restrictions are queried | |
348 | for all requests. | |
349 | * There are no defaults. | |
3794b2b6 | 350 | * There is also a 'cache_peer_access' tag in the ACL |
934b03fc | 351 | section. |
352 | DOC_END | |
353 | ||
354 | ||
355 | NAME: neighbor_type_domain | |
356 | TYPE: hostdomaintype | |
f1dc9b30 | 357 | DEFAULT: none |
358 | LOC: none | |
934b03fc | 359 | DOC_START |
360 | usage: neighbor_type_domain parent|sibling domain domain ... | |
361 | ||
362 | Modifying the neighbor type for specific domains is now | |
363 | possible. You can treat some domains differently than the the | |
a95856a0 | 364 | default neighbor type specified on the 'cache_peer' line. |
934b03fc | 365 | Normally it should only be necessary to list domains which |
366 | should be treated differently because the default neighbor type | |
367 | applies for hostnames which do not match domains listed here. | |
368 | ||
369 | EXAMPLE: | |
a95856a0 | 370 | cache_peer parent cache.foo.org 3128 3130 |
934b03fc | 371 | neighbor_type_domain cache.foo.org sibling .com .net |
372 | neighbor_type_domain cache.foo.org sibling .au .de | |
373 | DOC_END | |
374 | ||
465dc415 | 375 | NAME: icp_query_timeout |
376 | COMMENT: (msec) | |
377 | DEFAULT: 0 | |
378 | TYPE: int | |
379 | LOC: Config.Timeout.icp_query | |
934b03fc | 380 | DOC_START |
465dc415 | 381 | Normally Squid will automatically determine an optimal ICP |
382 | query timeout value based on the round-trip-time of recent ICP | |
383 | queries. If you want to override the value determined by | |
384 | Squid, set this 'icp_query_timeout' to a non-zero value. This | |
385 | value is specified in MILLISECONDS, so, to use a 2-second | |
386 | timeout (the old default), you would write: | |
934b03fc | 387 | |
465dc415 | 388 | icp_query_timeout 2000 |
465dc415 | 389 | DOC_END |
390 | ||
28993292 | 391 | NAME: maximum_icp_query_timeout |
392 | COMMENT: (msec) | |
393 | DEFAULT: 2000 | |
394 | TYPE: int | |
395 | LOC: Config.Timeout.icp_query_max | |
396 | DOC_START | |
efd900cb | 397 | Normally the ICP query timeout is determined dynamically. But |
398 | sometimes it can lead to very large values (say 5 seconds). | |
399 | Use this option to put an upper limit on the dynamic timeout | |
400 | value. Do NOT use this option to always use a fixed (instead | |
401 | of a dynamic) timeout value. | |
28993292 | 402 | |
efd900cb | 403 | If 'icp_query_timeout' is set to zero, then this value is |
404 | ignored. | |
28993292 | 405 | DOC_END |
406 | ||
465dc415 | 407 | NAME: mcast_icp_query_timeout |
408 | COMMENT: (msec) | |
409 | DEFAULT: 2000 | |
410 | TYPE: int | |
411 | LOC: Config.Timeout.mcast_icp_query | |
412 | DOC_START | |
413 | For Multicast peers, Squid regularly sends out ICP "probes" to | |
414 | count how many other peers are listening on the given multicast | |
415 | address. This value specifies how long Squid should wait to | |
416 | count all the replies. The default is 2000 msec, or 2 | |
417 | seconds. | |
934b03fc | 418 | DOC_END |
419 | ||
dc835977 | 420 | NAME: dead_peer_timeout |
421 | COMMENT: (seconds) | |
422 | DEFAULT: 10 seconds | |
423 | TYPE: time_t | |
424 | LOC: Config.Timeout.deadPeer | |
425 | DOC_START | |
426 | This controls how long Squid waits to declare a peer cache | |
427 | as "dead." If there are no ICP replies received in this | |
428 | amount of time, Squid will declare the peer dead and not | |
429 | expect to receive any further ICP replies. However, it | |
430 | continues to send ICP queries, and will mark the peer as | |
431 | alive upon receipt of the first subsequent ICP reply. | |
432 | ||
a8ad9a81 | 433 | This timeout also affects when Squid expects to receive ICP |
434 | replies from peers. If more than 'dead_peer' seconds have | |
435 | passed since the last ICP reply was received, Squid will not | |
436 | expect to receive an ICP reply on the next query. Thus, if | |
437 | your time between requests is greater than this timeout, you | |
438 | will see a lot of requests sent DIRECT to origin servers | |
439 | instead of to your parents. | |
dc835977 | 440 | DOC_END |
441 | ||
934b03fc | 442 | |
443 | NAME: hierarchy_stoplist | |
444 | TYPE: wordlist | |
f8d9f54a | 445 | DEFAULT: none |
934b03fc | 446 | LOC: Config.hierarchy_stoplist |
447 | DOC_START | |
448 | A list of words which, if found in a URL, cause the object to | |
449 | be handled directly by this cache. In other words, use this | |
450 | to not query neighbor caches for certain objects. You may | |
451 | list this option multiple times. | |
452 | ||
6b53c392 | 453 | NOCOMMENT_START |
454 | #We recommend you to use at least the following line. | |
934b03fc | 455 | hierarchy_stoplist cgi-bin ? |
6b53c392 | 456 | NOCOMMENT_END |
934b03fc | 457 | DOC_END |
458 | ||
459 | ||
bd05e3e3 | 460 | NAME: no_cache |
461 | TYPE: acl_access | |
462 | DEFAULT: none | |
463 | LOC: Config.accessList.noCache | |
934b03fc | 464 | DOC_START |
bd05e3e3 | 465 | A list of ACL elements which, if matched, cause the reply to |
934b03fc | 466 | immediately removed from the cache. In other words, use this |
bd05e3e3 | 467 | to force certain objects to never be cached. |
934b03fc | 468 | |
b269cf4e | 469 | You must use the word 'DENY' to indicate the ACL names which should |
470 | NOT be cached. | |
0fdafae7 | 471 | |
6b53c392 | 472 | NOCOMMENT_START |
473 | #We recommend you to use the following two lines. | |
bd05e3e3 | 474 | acl QUERY urlpath_regex cgi-bin \? |
b269cf4e | 475 | no_cache deny QUERY |
6b53c392 | 476 | NOCOMMENT_END |
934b03fc | 477 | DOC_END |
478 | ||
934b03fc | 479 | |
0f74202c | 480 | COMMENT_START |
3a278cb8 | 481 | OPTIONS WHICH AFFECT THE CACHE SIZE |
482 | ----------------------------------------------------------------------------- | |
0f74202c | 483 | COMMENT_END |
934b03fc | 484 | |
485 | NAME: cache_mem | |
9906e724 | 486 | COMMENT: (bytes) |
1b635117 | 487 | TYPE: b_size_t |
9906e724 | 488 | DEFAULT: 8 MB |
43a70238 | 489 | LOC: Config.memMaxSize |
934b03fc | 490 | DOC_START |
7b2496ca | 491 | NOTE: THIS PARAMETER DOES NOT SPECIFY THE MAXIMUM PROCESS |
492 | SIZE. IT PLACES A LIMIT ON ONE ASPECT OF SQUID'S MEMORY | |
493 | USAGE. SQUID USES MEMORY FOR OTHER THINGS AS WELL. | |
494 | YOUR PROCESS WILL PROBABLY BECOME TWICE OR THREE TIMES | |
495 | BIGGER THAN THE VALUE YOU PUT HERE | |
496 | ||
497 | 'cache_mem' specifies the ideal amount of memory to be used | |
498 | for: | |
499 | * In-Transit objects | |
500 | * Hot Objects | |
501 | * Negative-Cached objects | |
502 | ||
503 | Data for these objects are stored in 4 KB blocks. This | |
504 | parameter specifies the ideal upper limit on the total size of | |
505 | 4 KB blocks allocated. In-Transit objects take the highest | |
506 | priority. | |
934b03fc | 507 | |
508 | In-transit objects have priority over the others. When | |
509 | additional space is needed for incoming data, negative-cached | |
510 | and hot objects will be released. In other words, the | |
511 | negative-cached and hot objects will fill up any unused space | |
512 | not needed for in-transit objects. | |
513 | ||
7b2496ca | 514 | If circumstances require, this limit will be exceeded. |
515 | Specifically, if your incoming request rate requires more than | |
516 | 'cache_mem' of memory to hold in-transit objects, Squid will | |
517 | exceed this limit to satisfy the new requests. When the load | |
518 | decreases, blocks will be freed until the high-water mark is | |
519 | reached. Thereafter, blocks will be used to store hot | |
520 | objects. | |
934b03fc | 521 | DOC_END |
522 | ||
523 | ||
524 | NAME: cache_swap_low | |
525 | COMMENT: (percent, 0-100) | |
526 | TYPE: int | |
527 | DEFAULT: 90 | |
528 | LOC: Config.Swap.lowWaterMark | |
529 | DOC_NONE | |
530 | ||
531 | NAME: cache_swap_high | |
532 | COMMENT: (percent, 0-100) | |
533 | TYPE: int | |
534 | DEFAULT: 95 | |
535 | LOC: Config.Swap.highWaterMark | |
536 | DOC_START | |
2b906e48 | 537 | |
538 | The low- and high-water marks for cache object replacement. | |
539 | Replacement begins when the swap (disk) usage is above the | |
540 | low-water mark and attempts to maintain utilization near the | |
541 | low-water mark. As swap utilization gets close to high-water | |
542 | mark object eviction becomes more aggressive. If utilization is | |
543 | close to the low-water mark less replacement is done each time. | |
544 | ||
545 | Defaults are 90% and 95%. If you have a large cache, 5% could be | |
546 | hundreds of MB. If this is the case you may wish to set these | |
547 | numbers closer together. | |
934b03fc | 548 | DOC_END |
549 | ||
934b03fc | 550 | NAME: maximum_object_size |
9e975e4e | 551 | COMMENT: (bytes) |
1b635117 | 552 | TYPE: b_size_t |
9906e724 | 553 | DEFAULT: 4096 KB |
934b03fc | 554 | LOC: Config.Store.maxObjectSize |
555 | DOC_START | |
556 | Objects larger than this size will NOT be saved on disk. The | |
cf5cc17e | 557 | value is specified in kilobytes, and the default is 4MB. If |
558 | you wish to get a high BYTES hit ratio, you should probably | |
559 | increase this (one 32 MB object hit counts for 3200 10KB | |
560 | hits). If you wish to increase speed more than your want to | |
561 | save bandwidth you should leave this low. | |
934b03fc | 562 | |
2b906e48 | 563 | NOTE: if using the LFUDA replacement policy you should increase |
564 | this value to maximize the byte hit rate improvement of LFUDA! | |
565 | See replacement_policy below for a discussion of this policy. | |
934b03fc | 566 | DOC_END |
567 | ||
d20b1cd0 | 568 | NAME: minimum_object_size |
569 | COMMENT: (bytes) | |
570 | TYPE: b_size_t | |
571 | DEFAULT: 0 KB | |
572 | LOC: Config.Store.minObjectSize | |
573 | DOC_START | |
574 | Objects smaller than this size will NOT be saved on disk. The | |
575 | value is specified in kilobytes, and the default is 0 KB, which | |
576 | means there is no minimum. | |
577 | DOC_END | |
934b03fc | 578 | |
16689110 | 579 | NAME: maximum_object_size_in_memory |
580 | COMMENT: (bytes) | |
581 | TYPE: b_size_t | |
582 | DEFAULT: 8 KB | |
583 | LOC: Config.Store.maxInMemObjSize | |
584 | DOC_START | |
585 | Objects greater than this size will not be attempted to kept in | |
586 | the memory cache. This should be set high enough to keep objects | |
587 | accessed frequently in memory to improve performance whilst low | |
588 | enough to keep larger objects from hoarding cache_mem . | |
589 | DOC_END | |
590 | ||
934b03fc | 591 | NAME: ipcache_size |
592 | COMMENT: (number of entries) | |
593 | TYPE: int | |
594 | DEFAULT: 1024 | |
595 | LOC: Config.ipcache.size | |
596 | DOC_NONE | |
597 | ||
598 | NAME: ipcache_low | |
599 | COMMENT: (percent) | |
600 | TYPE: int | |
601 | DEFAULT: 90 | |
602 | LOC: Config.ipcache.low | |
603 | DOC_NONE | |
604 | ||
605 | NAME: ipcache_high | |
606 | COMMENT: (percent) | |
607 | TYPE: int | |
608 | DEFAULT: 95 | |
609 | LOC: Config.ipcache.high | |
610 | DOC_START | |
611 | The size, low-, and high-water marks for the IP cache. | |
934b03fc | 612 | DOC_END |
613 | ||
e55650e3 | 614 | NAME: fqdncache_size |
615 | COMMENT: (number of entries) | |
616 | TYPE: int | |
617 | DEFAULT: 1024 | |
618 | LOC: Config.fqdncache.size | |
619 | DOC_START | |
620 | Maximum number of FQDN cache entries. | |
e55650e3 | 621 | DOC_END |
622 | ||
6a566b9c | 623 | NAME: cache_replacement_policy |
624 | TYPE: removalpolicy | |
625 | LOC: Config.replPolicy | |
626 | DEFAULT: lru | |
627 | DOC_START | |
628 | The cache replacement policy parameter determines which | |
629 | objects are evicted (replaced) when disk space is needed. | |
630 | ||
631 | lru : Squid's original list based LRU policy | |
632 | heap GDSF : Greedy-Dual Size Frequency | |
633 | heap LFUDA: Least Frequently Used with Dynamic Aging | |
634 | heap LRU : LRU policy implemented using a heap | |
635 | ||
636 | Applies to any cache_dir lines listed below this. | |
637 | ||
638 | The LRU policies keeps recently referenced objects. | |
639 | ||
640 | The heap GDSF policy optimizes object hit rate by keeping smaller | |
641 | popular objects in cache so it has a better chance of getting a | |
642 | hit. It achieves a lower byte hit rate than LFUDA though since | |
643 | it evicts larger (possibly popular) objects. | |
644 | ||
645 | The heap LFUDA policy keeps popular objects in cache regardless of | |
646 | their size and thus optimizes byte hit rate at the expense of | |
647 | hit rate since one large, popular object will prevent many | |
648 | smaller, slightly less popular objects from being cached. | |
649 | ||
650 | Both policies utilize a dynamic aging mechanism that prevents | |
651 | cache pollution that can otherwise occur with frequency-based | |
652 | replacement policies. | |
653 | ||
654 | NOTE: if using the LFUDA replacement policy you should increase | |
655 | the value of maximum_object_size above its default of 4096 KB to | |
656 | to maximize the potential byte hit rate improvement of LFUDA. | |
657 | ||
658 | For more information about the GDSF and LFUDA cache replacement | |
659 | policies see http://www.hpl.hp.com/techreports/1999/HPL-1999-69.html | |
660 | and http://fog.hpl.external.hp.com/techreports/98/HPL-98-173.html. | |
661 | DOC_END | |
662 | ||
663 | NAME: memory_replacement_policy | |
664 | TYPE: removalpolicy | |
665 | LOC: Config.memPolicy | |
666 | DEFAULT: lru | |
667 | DOC_START | |
668 | The memory replacement policy parameter determines which | |
669 | objects are purged from memory when memory space is needed. | |
670 | ||
671 | See cache_replacement_policy for details. | |
672 | DOC_END | |
673 | ||
674 | ||
0f74202c | 675 | COMMENT_START |
3a278cb8 | 676 | LOGFILE PATHNAMES AND CACHE DIRECTORIES |
677 | ----------------------------------------------------------------------------- | |
0f74202c | 678 | COMMENT_END |
934b03fc | 679 | |
680 | NAME: cache_dir | |
681 | TYPE: cachedir | |
f1dc9b30 | 682 | DEFAULT: none |
cd748f27 | 683 | DEFAULT_IF_NONE: ufs -1 @DEFAULT_SWAP_DIR@ 100 16 256 |
f1dc9b30 | 684 | LOC: Config.cacheSwap |
934b03fc | 685 | DOC_START |
cf5cc17e | 686 | Usage: |
687 | ||
d1595b77 | 688 | cache_dir Type Maxobjsize Directory-Name Mbytes Level-1 Level2 [...] |
689 | ||
690 | DISKD Usage: | |
691 | ||
692 | cache_dir diskd Maxobjsize Directory-Name MB L1 L2 Q1 Q2 | |
934b03fc | 693 | |
694 | You can specify multiple cache_dir lines to spread the | |
695 | cache among different disk partitions. | |
696 | ||
efd900cb | 697 | Type specifies the kind of storage system to use. Most |
698 | everyone will want to use "ufs" as the type. If you are using | |
699 | Async I/O (--enable async-io) on Linux or Solaris, then you may | |
4813a665 | 700 | want to try "aufs" as the type. Async IO support may be |
efd900cb | 701 | buggy, however, so beware. |
9bc73deb | 702 | |
cd748f27 | 703 | Maxobjsize refers to the max object size this storedir supports. |
704 | It is used to initially choose the storedir to dump the object. | |
705 | -1 means 'any size'. | |
706 | ||
cf5cc17e | 707 | 'Directory' is a top-level directory where cache swap |
708 | files will be stored. If you want to use an entire disk | |
709 | for caching, then this can be the mount-point directory. | |
710 | The directory must exist and be writable by the Squid | |
711 | process. Squid will NOT create this directory for you. | |
712 | ||
713 | If no 'cache_dir' lines are specified, the following | |
714 | default will be used: @DEFAULT_SWAP_DIR@. | |
715 | ||
716 | 'Mbytes' is the amount of disk space (MB) to use under this | |
717 | directory. The default is 100 MB. Change this to suit your | |
718 | configuration. | |
719 | ||
720 | 'Level-1' is the number of first-level subdirectories which | |
721 | will be created under the 'Directory'. The default is 16. | |
722 | ||
723 | 'Level-2' is the number of second-level subdirectories which | |
724 | will be created under each first-level directory. The default | |
725 | is 256. | |
d1595b77 | 726 | |
727 | For the diskd type, Q1 specifies the number of unacknowledged | |
728 | I/O requests when Squid stops opening new files. If this | |
729 | many messages are in the queues, Squid won't open new files. | |
730 | Q2 specifies the number of unacknowledged messages when Squid | |
731 | starts blocking. If this many messages are in the queues, | |
732 | Squid blocks until it recevies some replies. | |
934b03fc | 733 | DOC_END |
734 | ||
735 | ||
736 | NAME: cache_access_log | |
737 | TYPE: string | |
d0b98f84 | 738 | DEFAULT: @DEFAULT_ACCESS_LOG@ |
934b03fc | 739 | LOC: Config.Log.access |
740 | DOC_START | |
741 | Logs the client request activity. Contains an entry for | |
0eb83825 | 742 | every HTTP and ICP queries received. To disable, enter "none". |
934b03fc | 743 | DOC_END |
744 | ||
745 | ||
746 | NAME: cache_log | |
747 | TYPE: string | |
0153d498 | 748 | DEFAULT: @DEFAULT_CACHE_LOG@ |
934b03fc | 749 | LOC: Config.Log.log |
750 | DOC_START | |
cf5cc17e | 751 | Cache logging file. This is where general information about |
efd900cb | 752 | your cache's behavior goes. You can increase the amount of data |
cf5cc17e | 753 | logged to this file with the "debug_options" tag below. |
934b03fc | 754 | DOC_END |
755 | ||
756 | ||
757 | NAME: cache_store_log | |
758 | TYPE: string | |
0153d498 | 759 | DEFAULT: @DEFAULT_STORE_LOG@ |
934b03fc | 760 | LOC: Config.Log.store |
761 | DOC_START | |
762 | Logs the activities of the storage manager. Shows which | |
763 | objects are ejected from the cache, and which objects are | |
cf5cc17e | 764 | saved and for how long. To disable, enter "none". There are |
efd900cb | 765 | not really utilities to analyze this data, so you can safely |
cf5cc17e | 766 | disable it. |
934b03fc | 767 | DOC_END |
768 | ||
769 | ||
770 | NAME: cache_swap_log | |
771 | TYPE: string | |
772 | LOC: Config.Log.swap | |
1273d501 | 773 | DEFAULT: none |
934b03fc | 774 | DOC_START |
d0d3ec94 | 775 | Location for the cache "swap.log." This log file holds the |
934b03fc | 776 | metadata of objects saved on disk. It is used to rebuild the |
a80e50c7 | 777 | cache during startup. Normally this file resides in each |
934b03fc | 778 | 'cache_dir' directory, but you may specify an alternate |
779 | pathname here. Note you must give a full filename, not just | |
cf5cc17e | 780 | a directory. Since this is the index for the whole object |
781 | list you CANNOT periodically rotate it! | |
934b03fc | 782 | |
a80e50c7 | 783 | If %s can be used in the file name then it will be replaced with a |
784 | a representation of the cache_dir name where each / is replaced | |
785 | with '.'. This is needed to allow adding/removing cache_dir | |
786 | lines when cache_swap_log is being used. | |
787 | ||
788 | If have more than one 'cache_dir', and %s is not used in the name | |
789 | then these swap logs will have names such as: | |
710df4ca | 790 | |
791 | cache_swap_log.00 | |
792 | cache_swap_log.01 | |
793 | cache_swap_log.02 | |
794 | ||
795 | The numbered extension (which is added automatically) | |
796 | corresponds to the order of the 'cache_dir' lines in this | |
797 | configuration file. If you change the order of the 'cache_dir' | |
798 | lines in this file, then these log files will NOT correspond to | |
799 | the correct 'cache_dir' entry (unless you manually rename | |
800 | them). We recommend that you do NOT use this option. It is | |
801 | better to keep these log files in each 'cache_dir' directory. | |
934b03fc | 802 | DOC_END |
803 | ||
804 | ||
805 | NAME: emulate_httpd_log | |
806 | COMMENT: on|off | |
807 | TYPE: onoff | |
f1dc9b30 | 808 | DEFAULT: off |
17a0a4ee | 809 | LOC: Config.onoff.common_log |
934b03fc | 810 | DOC_START |
811 | The Cache can emulate the log file format which many 'httpd' | |
812 | programs use. To disable/enable this emulation, set | |
813 | emulate_httpd_log to 'off' or 'on'. The default | |
cf5cc17e | 814 | is to use the native log format since it includes useful |
efd900cb | 815 | information that Squid-specific log analyzers use. |
934b03fc | 816 | DOC_END |
817 | ||
890b0fa8 | 818 | NAME: log_ip_on_direct |
819 | COMMENT: on|off | |
820 | TYPE: onoff | |
821 | DEFAULT: on | |
822 | LOC: Config.onoff.log_ip_on_direct | |
823 | DOC_START | |
824 | Log the destination IP address in the hierarchy log tag when going | |
825 | direct. Earlier Squid versions logged the hostname here. If you | |
826 | prefer the old way set this to off. | |
890b0fa8 | 827 | DOC_END |
934b03fc | 828 | |
829 | NAME: mime_table | |
f0b19334 | 830 | TYPE: string |
0153d498 | 831 | DEFAULT: @DEFAULT_MIME_TABLE@ |
934b03fc | 832 | LOC: Config.mimeTablePathname |
833 | DOC_START | |
cf5cc17e | 834 | Pathname to Squid's MIME table. You shouldn't need to change |
835 | this, but the default file contains examples and formatting | |
836 | information if you do. | |
934b03fc | 837 | DOC_END |
838 | ||
839 | ||
840 | NAME: log_mime_hdrs | |
841 | COMMENT: on|off | |
842 | TYPE: onoff | |
17a0a4ee | 843 | LOC: Config.onoff.log_mime_hdrs |
f1dc9b30 | 844 | DEFAULT: off |
934b03fc | 845 | DOC_START |
cf5cc17e | 846 | The Cache can record both the request and the response MIME |
847 | headers for each HTTP transaction. The headers are encoded | |
848 | safely and will appear as two bracketed fields at the end of | |
849 | the access log (for either the native or httpd-emulated log | |
850 | formats). To enable this logging set log_mime_hdrs to 'on'. | |
934b03fc | 851 | DOC_END |
852 | ||
853 | ||
854 | NAME: useragent_log | |
855 | TYPE: string | |
856 | LOC: Config.Log.useragent | |
f1dc9b30 | 857 | DEFAULT: none |
6b53c392 | 858 | IFDEF: USE_USERAGENT_LOG |
934b03fc | 859 | DOC_START |
6b53c392 | 860 | Squid will write the User-Agent field from HTTP requests |
861 | to the filename specified here. By default useragent_log | |
862 | is disabled. | |
934b03fc | 863 | DOC_END |
864 | ||
865 | ||
fd2c5549 | 866 | NAME: referer_log |
867 | TYPE: string | |
868 | LOC: Config.Log.referer | |
869 | DEFAULT: none | |
b81f1cf3 | 870 | IFDEF: USE_REFERER_LOG |
fd2c5549 | 871 | DOC_START |
b81f1cf3 | 872 | Squid will write the Referer field from HTTP requests to the |
873 | filename specified here. By default referer_log is disabled. | |
fd2c5549 | 874 | DOC_END |
875 | ||
876 | ||
934b03fc | 877 | NAME: pid_filename |
878 | TYPE: string | |
0153d498 | 879 | DEFAULT: @DEFAULT_PID_FILE@ |
934b03fc | 880 | LOC: Config.pidFilename |
881 | DOC_START | |
d0d41f07 | 882 | A filename to write the process-id to. To disable, enter "none". |
934b03fc | 883 | DOC_END |
884 | ||
885 | ||
886 | NAME: debug_options | |
f1dc9b30 | 887 | TYPE: eol |
934b03fc | 888 | DEFAULT: ALL,1 |
889 | LOC: Config.debugOptions | |
890 | DOC_START | |
891 | Logging options are set as section,level where each source file | |
892 | is assigned a unique section. Lower levels result in less | |
893 | output, Full debugging (level 9) can result in a very large | |
894 | log file, so be careful. The magic word "ALL" sets debugging | |
895 | levels for all sections. We recommend normally running with | |
896 | "ALL,1". | |
934b03fc | 897 | DOC_END |
898 | ||
899 | ||
934b03fc | 900 | NAME: log_fqdn |
901 | COMMENT: on|off | |
902 | TYPE: onoff | |
f1dc9b30 | 903 | DEFAULT: off |
17a0a4ee | 904 | LOC: Config.onoff.log_fqdn |
934b03fc | 905 | DOC_START |
906 | Turn this on if you wish to log fully qualified domain names | |
cf5cc17e | 907 | in the access.log. To do this Squid does a DNS lookup of all |
908 | IP's connecting to it. This can (in some situations) increase | |
909 | latency, which makes your cache seem slower for interactive | |
910 | browsing. | |
934b03fc | 911 | DOC_END |
912 | ||
913 | ||
914 | NAME: client_netmask | |
915 | TYPE: address | |
916 | LOC: Config.Addrs.client_netmask | |
f1dc9b30 | 917 | DEFAULT: 255.255.255.255 |
934b03fc | 918 | DOC_START |
919 | A netmask for client addresses in logfiles and cachemgr output. | |
920 | Change this to protect the privacy of your cache clients. | |
cf5cc17e | 921 | A netmask of 255.255.255.0 will log all IP's in that range with |
922 | the last digit set to '0'. | |
934b03fc | 923 | DOC_END |
924 | ||
925 | ||
0f74202c | 926 | COMMENT_START |
3a278cb8 | 927 | OPTIONS FOR EXTERNAL SUPPORT PROGRAMS |
928 | ----------------------------------------------------------------------------- | |
0f74202c | 929 | COMMENT_END |
934b03fc | 930 | |
934b03fc | 931 | NAME: ftp_user |
932 | TYPE: string | |
cf5cc17e | 933 | DEFAULT: Squid@ |
934b03fc | 934 | LOC: Config.Ftp.anon_user |
935 | DOC_START | |
936 | If you want the anonymous login password to be more informative | |
937 | (and enable the use of picky ftp servers), set this to something | |
efd900cb | 938 | reasonable for your domain, like wwwuser@somewhere.net |
934b03fc | 939 | |
940 | The reason why this is domainless by default is that the | |
941 | request can be made on the behalf of a user in any domain, | |
942 | depending on how the cache is used. | |
943 | Some ftp server also validate that the email address is valid | |
944 | (for example perl.com). | |
934b03fc | 945 | DOC_END |
946 | ||
365cb147 | 947 | NAME: ftp_list_width |
1b635117 | 948 | TYPE: size_t |
365cb147 | 949 | DEFAULT: 32 |
950 | LOC: Config.Ftp.list_width | |
951 | DOC_START | |
cf5cc17e | 952 | Sets the width of ftp listings. This should be set to fit in |
953 | the width of a standard browser. Setting this too small | |
954 | can cut off long filenames when browsing ftp sites. | |
365cb147 | 955 | DOC_END |
956 | ||
d20b1cd0 | 957 | NAME: ftp_passive |
958 | TYPE: onoff | |
959 | DEFAULT: on | |
960 | LOC: Config.Ftp.passive | |
961 | DOC_START | |
962 | If your firewall does not allow Squid to use passive | |
963 | connections, then turn off this option. | |
964 | DOC_END | |
965 | ||
934b03fc | 966 | NAME: cache_dns_program |
f0b19334 | 967 | TYPE: string |
589c90de | 968 | IFDEF: USE_DNSSERVERS |
0153d498 | 969 | DEFAULT: @DEFAULT_DNSSERVER@ |
934b03fc | 970 | LOC: Config.Program.dnsserver |
971 | DOC_START | |
972 | Specify the location of the executable for dnslookup process. | |
934b03fc | 973 | DOC_END |
974 | ||
934b03fc | 975 | NAME: dns_children |
976 | TYPE: int | |
6b53c392 | 977 | IFDEF: USE_DNSSERVERS |
934b03fc | 978 | DEFAULT: 5 |
979 | LOC: Config.dnsChildren | |
980 | DOC_START | |
981 | The number of processes spawn to service DNS name lookups. | |
982 | For heavily loaded caches on large servers, you should | |
983 | probably increase this value to at least 10. The maximum | |
984 | is 32. The default is 5. | |
985 | ||
efd900cb | 986 | You must have at least one dnsserver process. |
934b03fc | 987 | DOC_END |
988 | ||
4fe0e1d0 | 989 | NAME: dns_retransmit_interval |
990 | TYPE: time_t | |
991 | DEFAULT: 5 seconds | |
992 | LOC: Config.Timeout.idns_retransmit | |
993 | IFDEF: !USE_DNSSERVERS | |
994 | DOC_START | |
995 | Initial retransmit interval for DNS queries. The interval is | |
996 | doubled each time all configured DNS servers have been tried. | |
997 | ||
998 | DOC_END | |
999 | ||
1000 | NAME: dns_timeout | |
1001 | TYPE: time_t | |
1002 | DEFAULT: 5 minutes | |
1003 | LOC: Config.Timeout.idns_query | |
1004 | IFDEF: !USE_DNSSERVERS | |
1005 | DOC_START | |
1006 | DNS Query timeout. If no response is received to a DNS query | |
1007 | within this time then all DNS servers for the queried domain | |
1008 | is assumed to be unavailable. | |
1009 | DOC_END | |
934b03fc | 1010 | |
1011 | NAME: dns_defnames | |
1012 | COMMENT: on|off | |
589c90de | 1013 | IFDEF: USE_DNSSERVERS |
934b03fc | 1014 | TYPE: onoff |
f1dc9b30 | 1015 | DEFAULT: off |
17a0a4ee | 1016 | LOC: Config.onoff.res_defnames |
6b53c392 | 1017 | IFDEF: USE_DNSSERVERS |
934b03fc | 1018 | DOC_START |
1019 | Normally the 'dnsserver' disables the RES_DEFNAMES resolver | |
1020 | option (see res_init(3)). This prevents caches in a hierarchy | |
1021 | from interpreting single-component hostnames locally. To allow | |
1022 | dnsserver to handle single-component names, enable this | |
1023 | option. | |
934b03fc | 1024 | DOC_END |
1025 | ||
09c483ec | 1026 | NAME: dns_nameservers |
1027 | TYPE: wordlist | |
1028 | DEFAULT: none | |
1029 | LOC: Config.dns_nameservers | |
1030 | DOC_START | |
1031 | Use this if you want to specify a list of DNS name servers | |
1032 | (IP addresses) to use instead of those given in your | |
1033 | /etc/resolv.conf file. | |
1034 | ||
1035 | Example: dns_nameservers 10.0.0.1 192.172.0.4 | |
09c483ec | 1036 | DOC_END |
1037 | ||
0e70aa1e | 1038 | NAME: hosts_file |
1039 | TYPE: string | |
1040 | DEFAULT: /etc/hosts | |
1041 | LOC: Config.etcHostsPath | |
1042 | DOC_START | |
1043 | Location of the host-local IP name-address associations | |
1044 | database. Most Operating Systems have such a file: under | |
1045 | Un*X it's by default in /etc/hosts MS-Windows NT/2000 places | |
1046 | that in %SystemRoot%(by default | |
1047 | c:\winnt)\system32\drivers\etc\hosts, while Windows 9x/ME | |
1048 | places that in %windir%(usually c:\windows)\hosts | |
1049 | ||
1050 | The file contains newline-separated definitions, in the | |
1051 | form ip_address_in_dotted_form name [name ...] names are | |
1052 | whitespace-separated. lines beginnng with an hash (#) | |
1053 | character are comments. | |
1054 | ||
1055 | The file is checked at startup and upon configuration. If | |
1056 | set to 'none', it won't be checked. If append_domain is | |
1057 | used, that domain will be added to domain-local (i.e. not | |
1058 | containing any dot character) host definitions. | |
1059 | DOC_END | |
934b03fc | 1060 | |
1061 | NAME: unlinkd_program | |
a3d0a19d | 1062 | IFDEF: USE_UNLINKD |
f0b19334 | 1063 | TYPE: string |
0153d498 | 1064 | DEFAULT: @DEFAULT_UNLINKD@ |
934b03fc | 1065 | LOC: Config.Program.unlinkd |
1066 | DOC_START | |
1067 | Specify the location of the executable for file deletion process. | |
934b03fc | 1068 | DOC_END |
1069 | ||
934b03fc | 1070 | NAME: pinger_program |
a95856a0 | 1071 | TYPE: string |
0153d498 | 1072 | DEFAULT: @DEFAULT_PINGER@ |
934b03fc | 1073 | LOC: Config.Program.pinger |
6b53c392 | 1074 | IFDEF: USE_ICMP |
934b03fc | 1075 | DOC_START |
1076 | Specify the location of the executable for the pinger process. | |
d20b1cd0 | 1077 | This is only useful if you configured Squid (during compilation) |
1078 | with the '--enable-icmp' option. | |
934b03fc | 1079 | DOC_END |
1080 | ||
1081 | ||
1082 | NAME: redirect_program | |
c6d5b87b | 1083 | TYPE: wordlist |
934b03fc | 1084 | LOC: Config.Program.redirect |
62607543 | 1085 | DEFAULT: none |
934b03fc | 1086 | DOC_START |
1087 | Specify the location of the executable for the URL redirector. | |
cf5cc17e | 1088 | Since they can perform almost any function there isn't one included. |
1089 | See the Release-Notes for information on how to write one. | |
1090 | By default, a redirector is not used. | |
934b03fc | 1091 | DOC_END |
1092 | ||
1093 | ||
1094 | NAME: redirect_children | |
1095 | TYPE: int | |
1096 | DEFAULT: 5 | |
1097 | LOC: Config.redirectChildren | |
1098 | DOC_START | |
cf5cc17e | 1099 | The number of redirector processes to spawn. If you start |
1100 | too few Squid will have to wait for them to process a backlog of | |
1101 | URLs, slowing it down. If you start too many they will use RAM | |
1102 | and other system resources. | |
934b03fc | 1103 | DOC_END |
1104 | ||
c68e9c6b | 1105 | NAME: redirect_rewrites_host_header |
1106 | TYPE: onoff | |
1107 | DEFAULT: on | |
1108 | LOC: Config.onoff.redir_rewrites_host | |
1109 | DOC_START | |
7e3ce7b9 | 1110 | By default Squid rewrites any Host: header in redirected |
1111 | requests. If you are running a accelerator then this may | |
1112 | not be a wanted effect of a redirector. | |
c68e9c6b | 1113 | DOC_END |
1114 | ||
9bc73deb | 1115 | NAME: redirector_access |
1116 | TYPE: acl_access | |
1117 | DEFAULT: none | |
1118 | LOC: Config.accessList.redirector | |
1119 | DOC_START | |
1120 | If defined, this access list specifies which requests are | |
1121 | sent to the redirector processes. By default all requests | |
1122 | are sent. | |
1123 | DOC_END | |
1124 | ||
94439e4e | 1125 | NAME: auth_param |
1126 | TYPE: authparam | |
1127 | LOC: Config.authConfig | |
73e67ee0 | 1128 | DEFAULT: none |
1129 | DOC_START | |
94439e4e | 1130 | This is used to pass parameters to the various authentication |
1131 | schemes. | |
1132 | format: auth_param scheme parameter [setting] | |
1133 | ||
1134 | auth_param basic program @DEFAULT_PREFIX@/bin/ncsa_auth @DEFAULT_PREFIX@/etc/passwd | |
1135 | would tell the basic authentication scheme it's program parameter. | |
1136 | ||
1137 | The order that authentication prompts are presented to the client_agent | |
1138 | is dependant on the order the scheme first appears in config file. | |
1139 | IE has a bug (it's not rfc 2617 compliant) in that it will use the basic | |
1140 | scheme if basic is the first entry presented, even if more secure schemes | |
1141 | are presented. For now use the order in the file below. If other browsers | |
1142 | have difficulties (don't recognise the schemes offered even if you are using | |
1143 | basic) then either put basic first, or disable the other schemes (by commenting | |
1144 | out their program entry). | |
1145 | ||
1146 | === Parameters for the basic scheme follow. === | |
1147 | ||
1148 | "program" cmdline | |
6c20b822 | 1149 | Specify the command for the external authenticator. Such a |
1150 | program reads a line containing "username password" and replies | |
1151 | "OK" or "ERR" in an endless loop. If you use an authenticator, | |
1152 | make sure you have 1 acl of type proxy_auth. By default, the | |
94439e4e | 1153 | authenticate_program is not used. |
73e67ee0 | 1154 | |
6c20b822 | 1155 | If you want to use the traditional proxy authentication, |
1156 | jump over to the ../auth_modules/NCSA directory and | |
1157 | type: | |
1158 | % make | |
1159 | % make install | |
73e67ee0 | 1160 | |
6c20b822 | 1161 | Then, set this line to something like |
73e67ee0 | 1162 | |
94439e4e | 1163 | auth_param basic program @DEFAULT_PREFIX@/bin/ncsa_auth @DEFAULT_PREFIX@/etc/passwd |
73e67ee0 | 1164 | |
94439e4e | 1165 | "children" numberofchildren |
1166 | The number of authenticator processes to spawn (no default). If you | |
73e67ee0 | 1167 | start too few Squid will have to wait for them to process a backlog |
1168 | of usercode/password verifications, slowing it down. When password | |
1169 | verifications are done via a (slow) network you are likely to need | |
1170 | lots of authenticator processes. | |
94439e4e | 1171 | auth_param basic children 5 |
1172 | ||
1173 | "realm" realmstring | |
1174 | Specifies the realm name which is to be reported to the client for | |
1175 | the basic proxy authentication scheme (part of the text the user will | |
1176 | see when prompted their username and password). Their is no default. | |
1177 | auth_param basic realm Squid proxy-caching web server | |
1178 | ||
1179 | "credentialsttl" timetolive | |
1180 | Specifies how long squid assumes an externally validated username:password | |
1181 | pair is valid for - in other words how often the helper program is called | |
1182 | for that user. Set this low to force revalidation with short lived passwords. | |
1183 | Note that setting this high does not impact your susceptability to replay | |
1184 | attacks unless you are using a one-time password system (such as SecureID). | |
1185 | If you are using such a system, you will be vulnerable to replay attacks | |
1186 | unless you also enable the IP ttl is strict option. | |
1187 | ||
1188 | === NTLM scheme options follow === | |
1189 | ||
1190 | "program" cmdline | |
1191 | Specify the command for the external ntlm authenticator. Such a | |
1192 | program reads a line containing the uuencoded NEGOTIATE and replies | |
1193 | with the ntlm CHALLENGE, then waits for the response and answers with | |
1194 | "OK" or "ERR" in an endless loop. If you use an ntlm authenticator, | |
1195 | make sure you have 1 acl of type proxy_auth. By default, the | |
1196 | ntlm authenticator_program is not used. | |
1197 | ||
1198 | auth_param ntlm program @DEFAULT_PREFIX@/bin/ntlm_auth | |
1199 | ||
1200 | "children" numberofchildren | |
1201 | The number of authenticator processes to spawn (no default). If you | |
1202 | start too few Squid will have to wait for them to process a backlog | |
1203 | of credential verifications, slowing it down. When crendential | |
1204 | verifications are done via a (slow) network you are likely to need | |
1205 | lots of authenticator processes. | |
1206 | auth_param ntlm children 5 | |
1207 | ||
1208 | "max_challenge_reuses" number | |
1209 | The maximum number of times a challenge given by a ntlm authentication | |
1210 | helper can be reused. Increasing this number increases your exposure | |
1211 | to replay attacks on your network. 0 means use the challenge only once. | |
1212 | (disable challenge caching) | |
1213 | See max_ntlm_challenge_lifetime for more information. | |
1214 | auth_param ntlm max_challenge_reuses 0 | |
1215 | ||
1216 | "max_challenge_lifetime" timespan | |
1217 | The maximum time period that a ntlm challenge is reused over. | |
1218 | The actual period will be the minimum of this time AND the number of | |
1219 | reused challenges. | |
1220 | auth_param ntlm max_challenge_lifetime 2 minutes | |
1221 | ||
1222 | NOCOMMENT_START | |
1223 | #Recommended minimum configuration: | |
1224 | #auth_param ntlm program <uncomment and complete this line to activate> | |
1225 | auth_param ntlm children 5 | |
1226 | auth_param ntlm max_challenge_reuses 0 | |
1227 | auth_param ntlm max_challenge_lifetime 2 minutes | |
1228 | #auth_param basic program <uncomment and complete this line> | |
1229 | auth_param basic children 5 | |
1230 | auth_param basic realm Squid proxy-caching web server | |
1231 | auth_param basic credentialsttl 2 hours | |
1232 | NOCOMMENT_END | |
1233 | DOC_END | |
1234 | ||
1235 | NAME: authenticate_cache_garbage_interval | |
1236 | TYPE: time_t | |
1237 | DEFAULT: 1 hour | |
1238 | LOC: Config.authenticateGCInterval | |
1239 | DOC_START | |
1240 | The time period between garbage collection across the username cache. | |
1241 | This is a tradeoff between memory utilisation (long intervals - say | |
1242 | 2 days) and CPU (short intervals - say 1 minute). Only change if | |
1243 | you have good reason to. | |
73e67ee0 | 1244 | DOC_END |
1245 | ||
c68e9c6b | 1246 | NAME: authenticate_ttl |
70a76033 | 1247 | TYPE: time_t |
1248 | DEFAULT: 1 hour | |
c68e9c6b | 1249 | LOC: Config.authenticateTTL |
1250 | DOC_START | |
94439e4e | 1251 | The time a user & their credentials stay in the logged in user cache |
1252 | since their last request. When the garbage interval passes, all | |
1253 | user credentials that have passed their TTL are removed from memory. | |
c68e9c6b | 1254 | DOC_END |
1255 | ||
9bc73deb | 1256 | NAME: authenticate_ip_ttl |
70a76033 | 1257 | TYPE: time_t |
9bc73deb | 1258 | LOC: Config.authenticateIpTTL |
70a76033 | 1259 | DEFAULT: 0 seconds |
9bc73deb | 1260 | DOC_START |
1261 | With this option you control how long a proxy authentication | |
1262 | will be bound to a specific IP address. If a request using | |
1263 | the same user name is received during this time then access | |
1264 | will be denied and both users are required to reauthenticate | |
1265 | them selves. The idea behind this is to make it annoying | |
1266 | for people to share their password to their friends, but | |
1267 | yet allow a dialup user to reconnect on a different dialup | |
1268 | port. | |
1269 | ||
1270 | The default is 0 to disable the check. Recommended value | |
70a76033 | 1271 | if you have dialup users are no more than 60 seconds to allow |
1272 | the user to redial without hassle. If all your users are | |
1273 | stationary then higher values may be used. | |
1274 | ||
1275 | See also authenticate_ip_ttl_is_strict | |
1276 | DOC_END | |
1277 | ||
1278 | NAME: authenticate_ip_ttl_is_strict | |
1279 | TYPE: onoff | |
1280 | LOC: Config.onoff.authenticateIpTTLStrict | |
1281 | DEFAULT: on | |
1282 | DOC_START | |
94439e4e | 1283 | This option makes authenticate_ip_ttl a bit stricter. With this |
70a76033 | 1284 | enabled authenticate_ip_ttl will deny all access from other IP |
1285 | addresses until the TTL has expired, and the IP address "owning" | |
1286 | the userid will not be forced to reauthenticate. | |
9bc73deb | 1287 | DOC_END |
1288 | ||
0f74202c | 1289 | COMMENT_START |
3a278cb8 | 1290 | OPTIONS FOR TUNING THE CACHE |
1291 | ----------------------------------------------------------------------------- | |
0f74202c | 1292 | COMMENT_END |
934b03fc | 1293 | |
0153d498 | 1294 | NAME: wais_relay_host |
1295 | TYPE: string | |
1273d501 | 1296 | DEFAULT: none |
0153d498 | 1297 | LOC: Config.Wais.relayHost |
1298 | DOC_NONE | |
934b03fc | 1299 | |
0153d498 | 1300 | NAME: wais_relay_port |
1301 | TYPE: ushort | |
1302 | DEFAULT: 0 | |
1303 | LOC: Config.Wais.relayPort | |
934b03fc | 1304 | DOC_START |
1305 | Relay WAIS request to host (1st arg) at port (2 arg). | |
934b03fc | 1306 | DOC_END |
1307 | ||
1308 | ||
0483b991 | 1309 | NAME: request_header_max_size |
1310 | COMMENT: (KB) | |
1311 | TYPE: b_size_t | |
1312 | DEFAULT: 10 KB | |
1313 | LOC: Config.maxRequestHeaderSize | |
1314 | DOC_START | |
1315 | This specifies the maximum size for HTTP headers in a request. | |
1316 | Request headers are usually relatively small (about 512 bytes). | |
1317 | Placing a limit on the request header size will catch certain | |
1318 | bugs (for example with persistent connections) and possibly | |
1319 | buffer-overflow or denial-of-service attacks. | |
0483b991 | 1320 | DOC_END |
1321 | ||
1322 | NAME: request_body_max_size | |
9906e724 | 1323 | COMMENT: (KB) |
518da0bd | 1324 | TYPE: b_size_t |
1f38f50a | 1325 | DEFAULT: 1 MB |
0483b991 | 1326 | LOC: Config.maxRequestBodySize |
934b03fc | 1327 | DOC_START |
0483b991 | 1328 | This specifies the maximum size for an HTTP request body. |
1329 | In other words, the maximum size of a PUT/POST request. | |
1330 | A user who attempts to send a request with a body larger | |
1331 | than this limit receives an "Invalid Request" error message. | |
1332 | If you set this parameter to a zero, there will be no limit | |
1333 | imposed. | |
0483b991 | 1334 | DOC_END |
934b03fc | 1335 | |
0483b991 | 1336 | NAME: reply_body_max_size |
1337 | COMMENT: (KB) | |
1338 | TYPE: b_size_t | |
1339 | DEFAULT: 0 | |
1340 | LOC: Config.maxReplyBodySize | |
1341 | DOC_START | |
efd900cb | 1342 | This option specifies the maximum size of a reply body. It |
1343 | can be used to prevent users from downloading very large files, | |
1344 | such as MP3's and movies. The reply size is checked twice. | |
1345 | First when we get the reply headers, we check the | |
1346 | content-length value. If the content length value exists and | |
1347 | is larger than this parameter, the request is denied and the | |
1348 | user receives an error message that says "the request or reply | |
1349 | is too large." If there is no content-length, and the reply | |
1350 | size exceeds this limit, the client's connection is just closed | |
1351 | and they will receive a partial reply. | |
1352 | ||
1353 | NOTE: downstream caches probably can not detect a partial reply | |
1354 | if there is no content-length header, so they will cache | |
1355 | partial responses and give them out as hits. You should NOT | |
1356 | use this option if you have downstream caches. | |
1357 | ||
1358 | If you set this parameter to zero (the default), there will be | |
1359 | no limit imposed. | |
934b03fc | 1360 | DOC_END |
1361 | ||
1362 | ||
1363 | NAME: refresh_pattern | |
934b03fc | 1364 | TYPE: refreshpattern |
f1dc9b30 | 1365 | LOC: Config.Refresh |
1273d501 | 1366 | DEFAULT: none |
6b53c392 | 1367 | DEFAULT_IF_NONE: ^ftp: 1440 20% 10080 |
1368 | DEFAULT_IF_NONE: ^gopher: 1440 0% 1440 | |
1369 | DEFAULT_IF_NONE: . 0 20% 4320 | |
934b03fc | 1370 | DOC_START |
7ddc902f | 1371 | usage: refresh_pattern [-i] regex min percent max [options] |
1372 | ||
1373 | By default, regular expressions are CASE-SENSITIVE. To make | |
1374 | them case-insensitive, use the -i option. | |
934b03fc | 1375 | |
7e3ce7b9 | 1376 | 'Min' is the time (in minutes) an object without an explicit |
1377 | expiry time should be considered fresh. The recommended | |
1378 | value is 0, any higher values may cause dynamic applications | |
efd900cb | 1379 | to be erroneously cached unless the application designer |
7e3ce7b9 | 1380 | has taken the appropriate actions. |
1381 | ||
1382 | 'Percent' is a percentage of the objects age (time since last | |
efd900cb | 1383 | modification age) an object without explicit expiry time |
7e3ce7b9 | 1384 | will be considered fresh. |
1385 | ||
1386 | 'Max' is an upper limit on how long objects without an explicit | |
1387 | expiry time will be considered fresh. | |
934b03fc | 1388 | |
7e3ce7b9 | 1389 | options: overrsde-expire |
1dfa1d81 | 1390 | override-lastmod |
cbe3a719 | 1391 | reload-into-ims |
1392 | ignore-reload | |
1dfa1d81 | 1393 | |
1394 | override-expire enforces min age even if the server | |
cbe3a719 | 1395 | sent a Expires: header. Doing this VIOLATES the HTTP |
1396 | standard. Enabling this feature could make you liable | |
1397 | for problems which it causes. | |
1dfa1d81 | 1398 | |
1399 | override-lastmod enforces min age even on objects | |
1400 | that was modified recently. | |
cbe3a719 | 1401 | |
1402 | reload-into-ims changes client no-cache or ``reload'' | |
1403 | to If-Modified-Since requests. Doing this VIOLATES the | |
1404 | HTTP standard. Enabling this feature could make you | |
1405 | liable for problems which it causes. | |
1406 | ||
1407 | ignore-reload ignores a client no-cache or ``reload'' | |
1408 | header. Doing this VIOLATES the HTTP standard. Enabling | |
1409 | this feature could make you liable for problems which | |
1410 | it causes. | |
1dfa1d81 | 1411 | |
934b03fc | 1412 | Please see the file doc/Release-Notes-1.1.txt for a full |
1413 | description of Squid's refresh algorithm. Basically a | |
1dfa1d81 | 1414 | cached object is: (the order is changed from 1.1.X) |
934b03fc | 1415 | |
1dfa1d81 | 1416 | FRESH if expires < now, else STALE |
6b8e7481 | 1417 | STALE if age > max |
1dfa1d81 | 1418 | FRESH if lm-factor < percent, else STALE |
1419 | FRESH if age < min | |
1420 | else STALE | |
934b03fc | 1421 | |
1422 | The refresh_pattern lines are checked in the order listed here. | |
1423 | The first entry which matches is used. If none of the entries | |
1424 | match, then the default will be used. | |
1425 | ||
6b53c392 | 1426 | Note, you must uncomment all the default lines if you want |
1427 | to change one. The default setting is only active if none is | |
1428 | used. | |
934b03fc | 1429 | DOC_END |
1430 | ||
934b03fc | 1431 | NAME: reference_age |
f1dc9b30 | 1432 | TYPE: time_t |
934b03fc | 1433 | LOC: Config.referenceAge |
f1dc9b30 | 1434 | DEFAULT: 1 year |
934b03fc | 1435 | DOC_START |
1436 | As a part of normal operation, Squid performs Least Recently | |
1437 | Used removal of cached objects. The LRU age for removal is | |
1438 | computed dynamically, based on the amount of disk space in | |
6778c757 | 1439 | use. The dynamic value can be seen in the Cache Manager 'info' |
1440 | output. | |
1441 | ||
1442 | The 'reference_age' parameter defines the maximum LRU age. For | |
1443 | example, setting reference_age to '1 week' will cause objects | |
1444 | to be removed if they have not been accessed for a week or | |
7e3ce7b9 | 1445 | more. The default value is one year. |
934b03fc | 1446 | |
1447 | Specify a number here, followed by units of time. For example: | |
1448 | 1 week | |
1449 | 3.5 days | |
1450 | 4 months | |
1451 | 2.2 hours | |
1452 | ||
2b906e48 | 1453 | NOTE: this parameter is not used when using the enhanced |
1454 | replacement policies, GDSH or LFUDA. | |
934b03fc | 1455 | DOC_END |
1456 | ||
1457 | ||
0153d498 | 1458 | NAME: quick_abort_min |
9906e724 | 1459 | COMMENT: (KB) |
1460 | TYPE: kb_size_t | |
c68e9c6b | 1461 | DEFAULT: 16 KB |
0153d498 | 1462 | LOC: Config.quickAbort.min |
1463 | DOC_NONE | |
1464 | ||
0153d498 | 1465 | NAME: quick_abort_max |
9906e724 | 1466 | COMMENT: (KB) |
1467 | TYPE: kb_size_t | |
6b53c392 | 1468 | DEFAULT: 16 KB |
0153d498 | 1469 | LOC: Config.quickAbort.max |
1b2f5c2f | 1470 | DOC_NONE |
1471 | ||
1472 | NAME: quick_abort_pct | |
1473 | COMMENT: (percent) | |
1474 | TYPE: int | |
c68e9c6b | 1475 | DEFAULT: 95 |
1b2f5c2f | 1476 | LOC: Config.quickAbort.pct |
934b03fc | 1477 | DOC_START |
cf5cc17e | 1478 | The cache can be configured to continue downloading aborted |
1479 | requests. This may be undesirable on slow (e.g. SLIP) links | |
1480 | and/or very busy caches. Impatient users may tie up file | |
1481 | descriptors and bandwidth by repeatedly requesting and | |
1482 | immediately aborting downloads. | |
934b03fc | 1483 | |
1484 | When the user aborts a request, Squid will check the | |
1485 | quick_abort values to the amount of data transfered until | |
1486 | then. | |
1487 | ||
cf5cc17e | 1488 | If the transfer has less than 'quick_abort_min' KB remaining, |
1489 | it will finish the retrieval. Setting 'quick_abort_min' to -1 | |
1490 | will disable the quick_abort feature. | |
934b03fc | 1491 | |
cf5cc17e | 1492 | If the transfer has more than 'quick_abort_max' KB remaining, |
1493 | it will abort the retrieval. | |
934b03fc | 1494 | |
1b2f5c2f | 1495 | If more than 'quick_abort_pct' of the transfer has completed, |
1496 | it will finish the retrieval. | |
934b03fc | 1497 | DOC_END |
1498 | ||
1499 | ||
1500 | NAME: negative_ttl | |
bc0eb004 | 1501 | COMMENT: time-units |
f1dc9b30 | 1502 | TYPE: time_t |
934b03fc | 1503 | LOC: Config.negativeTtl |
9e975e4e | 1504 | DEFAULT: 5 minutes |
934b03fc | 1505 | DOC_START |
1506 | Time-to-Live (TTL) for failed requests. Certain types of | |
1507 | failures (such as "connection refused" and "404 Not Found") are | |
cf5cc17e | 1508 | negatively-cached for a configurable amount of time. The |
1509 | default is 5 minutes. Note that this is different from | |
1510 | negative caching of DNS lookups. | |
934b03fc | 1511 | DOC_END |
1512 | ||
1513 | ||
1514 | NAME: positive_dns_ttl | |
bc0eb004 | 1515 | COMMENT: time-units |
f1dc9b30 | 1516 | TYPE: time_t |
934b03fc | 1517 | LOC: Config.positiveDnsTtl |
9e975e4e | 1518 | DEFAULT: 6 hours |
934b03fc | 1519 | DOC_START |
1520 | Time-to-Live (TTL) for positive caching of successful DNS lookups. | |
1521 | Default is 6 hours (360 minutes). If you want to minimize the | |
1522 | use of Squid's ipcache, set this to 1, not 0. | |
934b03fc | 1523 | DOC_END |
1524 | ||
1525 | ||
1526 | NAME: negative_dns_ttl | |
bc0eb004 | 1527 | COMMENT: time-units |
f1dc9b30 | 1528 | TYPE: time_t |
934b03fc | 1529 | LOC: Config.negativeDnsTtl |
9e975e4e | 1530 | DEFAULT: 5 minutes |
934b03fc | 1531 | DOC_START |
1532 | Time-to-Live (TTL) for negative caching of failed DNS lookups. | |
934b03fc | 1533 | DOC_END |
1534 | ||
c68e9c6b | 1535 | NAME: range_offset_limit |
1536 | COMMENT: (bytes) | |
1537 | TYPE: b_size_t | |
1538 | LOC: Config.rangeOffsetLimit | |
1539 | DEFAULT: 0 KB | |
1540 | DOC_START | |
1541 | Sets a upper limit on how far into the the file a Range request | |
1542 | may be to cause Squid to prefetch the whole file. If beyond this | |
1543 | limit then Squid forwards the Range request as it is and the result | |
1544 | is NOT cached. | |
1545 | ||
1546 | This is to stop a far ahead range request (lets say start at 17MB) | |
1547 | from making Squid fetch the whole object up to that point before | |
1548 | sending anything to the client. | |
1549 | ||
1550 | A value of -1 causes Squid to always fetch the object from the | |
1551 | beginning so that it may cache the result. (2.0 style) | |
1552 | ||
6e7dbcbd | 1553 | A value of 0 causes Squid to never fetch more than the |
c68e9c6b | 1554 | client requested. (default) |
c68e9c6b | 1555 | DOC_END |
1556 | ||
1557 | ||
0f74202c | 1558 | COMMENT_START |
3a278cb8 | 1559 | TIMEOUTS |
1560 | ----------------------------------------------------------------------------- | |
0f74202c | 1561 | COMMENT_END |
934b03fc | 1562 | |
1563 | NAME: connect_timeout | |
bc0eb004 | 1564 | COMMENT: time-units |
f1dc9b30 | 1565 | TYPE: time_t |
934b03fc | 1566 | LOC: Config.Timeout.connect |
9e975e4e | 1567 | DEFAULT: 2 minutes |
934b03fc | 1568 | DOC_START |
1569 | Some systems (notably Linux) can not be relied upon to properly | |
cf5cc17e | 1570 | time out connect(2) requests. Therefore the Squid process |
934b03fc | 1571 | enforces its own timeout on server connections. This parameter |
1572 | specifies how long to wait for the connect to complete. The | |
1573 | default is two minutes (120 seconds). | |
934b03fc | 1574 | DOC_END |
1575 | ||
3f62decd | 1576 | NAME: peer_connect_timeout |
1577 | COMMENT: time-units | |
1578 | TYPE: time_t | |
1579 | LOC: Config.Timeout.peer_connect | |
1580 | DEFAULT: 30 seconds | |
1581 | DOC_START | |
1582 | This parameter specifies how long to wait for a pending TCP | |
1583 | connection to a peer cache. The default is 30 seconds. You | |
1584 | may also set different timeout values for individual neighbors | |
1585 | with the 'connect-timeout' option on a 'cache_peer' line. | |
9bc73deb | 1586 | DOC_END |
3f62decd | 1587 | |
23d92c64 | 1588 | NAME: siteselect_timeout |
1589 | COMMENT: time-units | |
1590 | TYPE: time_t | |
1591 | LOC: Config.Timeout.siteSelect | |
1592 | DEFAULT: 4 seconds | |
1593 | DOC_START | |
1594 | For URN to multiple URL's URL selection | |
23d92c64 | 1595 | DOC_END |
934b03fc | 1596 | |
1597 | NAME: read_timeout | |
bc0eb004 | 1598 | COMMENT: time-units |
f1dc9b30 | 1599 | TYPE: time_t |
934b03fc | 1600 | LOC: Config.Timeout.read |
9e975e4e | 1601 | DEFAULT: 15 minutes |
934b03fc | 1602 | DOC_START |
1603 | The read_timeout is applied on server-side connections. After | |
1604 | each successful read(), the timeout will be extended by this | |
1605 | amount. If no data is read again after this amount of time, | |
1606 | the request is aborted and logged with ERR_READ_TIMEOUT. The | |
1607 | default is 15 minutes. | |
934b03fc | 1608 | DOC_END |
1609 | ||
1610 | ||
934b03fc | 1611 | NAME: request_timeout |
f1dc9b30 | 1612 | TYPE: time_t |
934b03fc | 1613 | LOC: Config.Timeout.request |
9e975e4e | 1614 | DEFAULT: 30 seconds |
934b03fc | 1615 | DOC_START |
1616 | How long to wait for an HTTP request after connection | |
1617 | establishment. For persistent connections, wait this long | |
1618 | after the previous request completes. | |
934b03fc | 1619 | DOC_END |
1620 | ||
1621 | ||
1622 | NAME: client_lifetime | |
bc0eb004 | 1623 | COMMENT: time-units |
f1dc9b30 | 1624 | TYPE: time_t |
934b03fc | 1625 | LOC: Config.Timeout.lifetime |
9e975e4e | 1626 | DEFAULT: 1 day |
934b03fc | 1627 | DOC_START |
1628 | The maximum amount of time that a client (browser) is allowed to | |
1629 | remain connected to the cache process. This protects the Cache | |
efd900cb | 1630 | from having a lot of sockets (and hence file descriptors) tied up |
934b03fc | 1631 | in a CLOSE_WAIT state from remote clients that go away without |
1632 | properly shutting down (either because of a network failure or | |
1633 | because of a poor client implementation). The default is one | |
1634 | day, 1440 minutes. | |
1635 | ||
1636 | NOTE: The default value is intended to be much larger than any | |
1637 | client would ever need to be connected to your cache. You | |
1638 | should probably change client_lifetime only as a last resort. | |
1639 | If you seem to have many client connections tying up | |
1640 | filedescriptors, we recommend first tuning the read_timeout, | |
0fbcf3c7 | 1641 | request_timeout, pconn_timeout and quick_abort values. |
934b03fc | 1642 | DOC_END |
1643 | ||
ea285003 | 1644 | NAME: half_closed_clients |
1645 | TYPE: onoff | |
1646 | LOC: Config.onoff.half_closed_clients | |
1647 | DEFAULT: on | |
1648 | DOC_START | |
1649 | Some clients may shutdown the sending side of their TCP | |
1650 | connections, while leaving their receiving sides open. Sometimes, | |
1651 | Squid can not tell the difference between a half-closed and a | |
1652 | fully-closed TCP connection. By default, half-closed client | |
1653 | connections are kept open until a read(2) or write(2) on the | |
1654 | socket returns an error. Change this option to 'off' and Squid | |
1655 | will immediately close client connections when read(2) returns | |
1656 | "no more data to read." | |
ea285003 | 1657 | DOC_END |
1658 | ||
603a02fd | 1659 | NAME: pconn_timeout |
1660 | TYPE: time_t | |
1661 | LOC: Config.Timeout.pconn | |
1662 | DEFAULT: 120 seconds | |
1663 | DOC_START | |
1664 | Timeout for idle persistent connections to servers and other | |
1665 | proxies. | |
603a02fd | 1666 | DOC_END |
1667 | ||
05832ae1 | 1668 | NAME: ident_timeout |
1669 | TYPE: time_t | |
3898f57f | 1670 | IFDEF: USE_IDENT |
05832ae1 | 1671 | LOC: Config.Timeout.ident |
1672 | DEFAULT: 10 seconds | |
1673 | DOC_START | |
1674 | Maximum time to wait for IDENT requests. If this is too high, | |
1675 | and you enabled 'ident_lookup', then you might be susceptible | |
1676 | to denial-of-service by having many ident requests going at | |
1677 | once. | |
6b8e7481 | 1678 | |
9bc73deb | 1679 | Only src type ACL checks are fully supported. A src_domain |
1680 | ACL might work at times, but it will not always provide | |
1681 | the correct result. | |
1682 | ||
6b8e7481 | 1683 | This option may be disabled by using --disable-ident with |
1684 | the configure script. | |
05832ae1 | 1685 | DOC_END |
1686 | ||
934b03fc | 1687 | |
1688 | NAME: shutdown_lifetime | |
bc0eb004 | 1689 | COMMENT: time-units |
f1dc9b30 | 1690 | TYPE: time_t |
934b03fc | 1691 | LOC: Config.shutdownLifetime |
9e975e4e | 1692 | DEFAULT: 30 seconds |
934b03fc | 1693 | DOC_START |
1694 | When SIGTERM or SIGHUP is received, the cache is put into | |
1695 | "shutdown pending" mode until all active sockets are closed. | |
1696 | This value is the lifetime to set for all open descriptors | |
1697 | during shutdown mode. Any active clients after this many | |
1698 | seconds will receive a 'timeout' message. | |
934b03fc | 1699 | DOC_END |
1700 | ||
0f74202c | 1701 | COMMENT_START |
3a278cb8 | 1702 | ACCESS CONTROLS |
1703 | ----------------------------------------------------------------------------- | |
0f74202c | 1704 | COMMENT_END |
934b03fc | 1705 | |
1706 | NAME: acl | |
1707 | TYPE: acl | |
f1dc9b30 | 1708 | LOC: Config.aclList |
1709 | DEFAULT: none | |
934b03fc | 1710 | DOC_START |
1711 | Defining an Access List | |
1712 | ||
1713 | acl aclname acltype string1 ... | |
1714 | acl aclname acltype "file" ... | |
1715 | ||
1716 | when using "file", the file should contain one item per line | |
1717 | ||
1718 | acltype is one of src dst srcdomain dstdomain url_pattern | |
1719 | urlpath_pattern time port proto method browser user | |
1720 | ||
edd80fbb | 1721 | By default, regular expressions are CASE-SENSITIVE. To make |
1722 | them case-insensitive, use the -i option. | |
1723 | ||
934b03fc | 1724 | acl aclname src ip-address/netmask ... (clients IP address) |
1725 | acl aclname src addr1-addr2/netmask ... (range of addresses) | |
1726 | acl aclname dst ip-address/netmask ... (URL host's IP address) | |
ae2c08a2 | 1727 | acl aclname myip ip-address/netmask ... (local socket IP address) |
d0d41f07 | 1728 | |
efd900cb | 1729 | acl aclname srcdomain .foo.com ... # reverse lookup, client IP |
1730 | acl aclname dstdomain .foo.com ... # Destination server from URL | |
edd80fbb | 1731 | acl aclname srcdom_regex [-i] xxx ... # regex matching client name |
1732 | acl aclname dstdom_regex [-i] xxx ... # regex matching server | |
d0d41f07 | 1733 | # For dstdomain and dstdom_regex a reverse lookup is tried if a IP |
1734 | # based URL is used. The name "none" is used if the reverse lookup | |
1735 | # fails. | |
1736 | ||
934b03fc | 1737 | acl aclname time [day-abbrevs] [h1:m1-h2:m2] |
1738 | day-abbrevs: | |
1739 | S - Sunday | |
1740 | M - Monday | |
1741 | T - Tuesday | |
1742 | W - Wednesday | |
1743 | H - Thursday | |
1744 | F - Friday | |
1745 | A - Saturday | |
1746 | h1:m1 must be less than h2:m2 | |
edd80fbb | 1747 | acl aclname url_regex [-i] ^http:// ... # regex matching on whole URL |
1748 | acl aclname urlpath_regex [-i] \.gif$ ... # regex matching on URL path | |
934b03fc | 1749 | acl aclname port 80 70 21 ... |
ec5bba4d | 1750 | acl aclname port 0-1024 ... # ranges allowed |
7e3ce7b9 | 1751 | acl aclname myport 3128 ... # (local socket TCP port) |
934b03fc | 1752 | acl aclname proto HTTP FTP ... |
1753 | acl aclname method GET POST ... | |
edd80fbb | 1754 | acl aclname browser [-i] regexp |
1755 | # pattern match on User-Agent header | |
c68e9c6b | 1756 | acl aclname ident username ... |
145cf928 | 1757 | acl aclname ident_regex [-i] pattern ... |
c68e9c6b | 1758 | # string match on ident output. |
1759 | # use REQUIRED to accept any non-null ident. | |
6468fe10 | 1760 | acl aclname src_as number ... |
1761 | acl aclname dst_as number ... | |
1762 | # Except for access control, AS numbers can be used for | |
1763 | # routing of requests to specific caches. Here's an | |
1764 | # example for routing all requests for AS#1241 and only | |
1765 | # those to mycache.mydomain.net: | |
1766 | # acl asexample dst_as 1241 | |
d87ebd78 | 1767 | # cache_peer_access mycache.mydomain.net allow asexample |
1768 | # cache_peer_access mycache_mydomain.net deny all | |
6468fe10 | 1769 | |
c68e9c6b | 1770 | acl aclname proxy_auth username ... |
145cf928 | 1771 | acl aclname proxy_auth_regex [-i] pattern ... |
c68e9c6b | 1772 | # list of valid usernames |
1773 | # use REQUIRED to accept any valid username. | |
73e67ee0 | 1774 | # |
1775 | # NOTE: when a Proxy-Authentication header is sent but it is not | |
1776 | # needed during ACL checking the username is NOT logged | |
1777 | # in access.log. | |
c68e9c6b | 1778 | # |
1779 | # NOTE: proxy_auth requires a EXTERNAL authentication program | |
1780 | # to check username/password combinations (see | |
1781 | # authenticate_program). | |
1782 | # | |
1783 | # WARNING: proxy_auth can't be used in a transparent proxy. It | |
1784 | # collides with any authentication done by origin servers. It may | |
1785 | # seem like it works at first, but it doesn't. | |
934b03fc | 1786 | |
dba79ac5 | 1787 | acl aclname snmp_community string ... |
08f6b5e0 | 1788 | # A community string to limit access to your SNMP Agent |
dba79ac5 | 1789 | # Example: |
1790 | # | |
1791 | # acl snmppublic snmp_community public | |
1792 | ||
9bc73deb | 1793 | acl aclname maxconn number |
1794 | # This will be matched when the client's IP address has | |
1795 | # more than <number> HTTP connections established. | |
1796 | ||
ba2b31a8 | 1797 | acl req_mime_type mime-type1 ... |
1798 | # regex match agains the mime type of the request generated | |
1799 | # by the client. Can be used to detect file upload or some | |
1800 | # types HTTP tunelling requests. | |
1801 | # NOTE: This does NOT match the reply. You cannot use this | |
1802 | # to match the returned file type. | |
c68e9c6b | 1803 | |
1804 | Examples: | |
1805 | acl myexample dst_as 1241 | |
aa6956a5 | 1806 | acl password proxy_auth REQUIRED |
ba2b31a8 | 1807 | acl fileupload req_mime_type -i ^multipart/form-data$ |
c68e9c6b | 1808 | |
c68e9c6b | 1809 | NOCOMMENT_START |
6b53c392 | 1810 | #Recommended minimum configuration: |
c68e9c6b | 1811 | acl all src 0.0.0.0/0.0.0.0 |
934b03fc | 1812 | acl manager proto cache_object |
1813 | acl localhost src 127.0.0.1/255.255.255.255 | |
934b03fc | 1814 | acl SSL_ports port 443 563 |
6b53c392 | 1815 | acl Safe_ports port 80 # http |
1816 | acl Safe_ports port 21 # ftp | |
1817 | acl Safe_ports port 443 563 # https, snews | |
1818 | acl Safe_ports port 70 # gopher | |
1819 | acl Safe_ports port 210 # wais | |
1820 | acl Safe_ports port 1025-65535 # unregistered ports | |
9bc73deb | 1821 | acl Safe_ports port 280 # http-mgmt |
1822 | acl Safe_ports port 488 # gss-http | |
1823 | acl Safe_ports port 591 # filemaker | |
1824 | acl Safe_ports port 777 # multiling http | |
934b03fc | 1825 | acl CONNECT method CONNECT |
c68e9c6b | 1826 | NOCOMMENT_END |
934b03fc | 1827 | DOC_END |
1828 | ||
1829 | NAME: http_access | |
1830 | TYPE: acl_access | |
f1dc9b30 | 1831 | LOC: Config.accessList.http |
1832 | DEFAULT: none | |
da7f354f | 1833 | DEFAULT_IF_NONE: deny all |
934b03fc | 1834 | DOC_START |
1835 | Allowing or Denying access based on defined access lists | |
1836 | ||
1837 | Access to the HTTP port: | |
1838 | http_access allow|deny [!]aclname ... | |
1839 | ||
934b03fc | 1840 | NOTE on default values: |
1841 | ||
6b53c392 | 1842 | If there are no "access" lines present, the default is to deny |
934b03fc | 1843 | the request. |
1844 | ||
1845 | If none of the "access" lines cause a match, the default is the | |
1846 | opposite of the last line in the list. If the last line was | |
1847 | deny, then the default is allow. Conversely, if the last line | |
1848 | is allow, the default will be deny. For these reasons, it is a | |
1849 | good idea to have an "deny all" or "allow all" entry at the end | |
1850 | of your access lists to avoid potential confusion. | |
1851 | ||
c68e9c6b | 1852 | NOCOMMENT_START |
6b53c392 | 1853 | #Recommended minimum configuration: |
1854 | # | |
1855 | # Only allow cachemgr access from localhost | |
c68e9c6b | 1856 | http_access allow manager localhost |
1857 | http_access deny manager | |
6b53c392 | 1858 | # Deny requests to unknown ports |
499558df | 1859 | http_access deny !Safe_ports |
6b53c392 | 1860 | # Deny CONNECT to other than SSL ports |
c68e9c6b | 1861 | http_access deny CONNECT !SSL_ports |
1862 | # | |
1863 | # INSERT YOUR OWN RULE(S) HERE TO ALLOW ACCESS FROM YOUR CLIENTS | |
1864 | # | |
6b53c392 | 1865 | # And finally deny all other access to this proxy |
c68e9c6b | 1866 | http_access deny all |
1867 | NOCOMMENT_END | |
934b03fc | 1868 | DOC_END |
1869 | ||
1870 | ||
1871 | NAME: icp_access | |
1872 | TYPE: acl_access | |
f1dc9b30 | 1873 | LOC: Config.accessList.icp |
1874 | DEFAULT: none | |
da7f354f | 1875 | DEFAULT_IF_NONE: deny all |
934b03fc | 1876 | DOC_START |
6b53c392 | 1877 | Allowing or Denying access to the ICP port based on defined |
1878 | access lists | |
1879 | ||
1880 | icp_access allow|deny [!]aclname ... | |
1881 | ||
1882 | See http_access for details | |
934b03fc | 1883 | |
c68e9c6b | 1884 | NOCOMMENT_START |
6b53c392 | 1885 | #Allow ICP queries from eveyone |
c68e9c6b | 1886 | icp_access allow all |
1887 | NOCOMMENT_END | |
934b03fc | 1888 | DOC_END |
1889 | ||
1890 | ||
1891 | NAME: miss_access | |
1892 | TYPE: acl_access | |
f1dc9b30 | 1893 | LOC: Config.accessList.miss |
1894 | DEFAULT: none | |
934b03fc | 1895 | DOC_START |
1896 | Use to force your neighbors to use you as a sibling instead of | |
1897 | a parent. For example: | |
1898 | ||
1899 | acl localclients src 172.16.0.0/16 | |
1900 | miss_access allow localclients | |
1901 | miss_access deny !localclients | |
1902 | ||
1903 | This means that only your local clients are allowed to fetch | |
1904 | MISSES and all other clients can only fetch HITS. | |
1905 | ||
1906 | By default, allow all clients who passed the http_access rules | |
1907 | to fetch MISSES from us. | |
6b53c392 | 1908 | |
c68e9c6b | 1909 | NOCOMMENT_START |
6b53c392 | 1910 | #Default setting: |
1911 | # miss_access allow all | |
c68e9c6b | 1912 | NOCOMMENT_END |
934b03fc | 1913 | DOC_END |
1914 | ||
1915 | ||
505e35db | 1916 | NAME: cache_peer_access |
1917 | TYPE: peer_access | |
f1dc9b30 | 1918 | DEFAULT: none |
1919 | LOC: none | |
934b03fc | 1920 | DOC_START |
505e35db | 1921 | Similar to 'cache_peer_domain' but provides more flexibility by |
1922 | using ACL elements. | |
934b03fc | 1923 | |
505e35db | 1924 | cache_peer_access cache-host allow|deny [!]aclname ... |
934b03fc | 1925 | |
505e35db | 1926 | The syntax is identical to 'http_access' and the other lists of |
1927 | ACL elements. See the comments for 'http_access' below, or | |
2b6662ba | 1928 | the Squid FAQ (http://www.squid-cache.org/FAQ/FAQ-10.html). |
934b03fc | 1929 | DOC_END |
1930 | ||
ec603b25 | 1931 | NAME: ident_lookup_access |
1932 | TYPE: acl_access | |
1933 | IFDEF: USE_IDENT | |
1934 | DEFAULT: none | |
1935 | DEFAULT_IF_NONE: deny all | |
1936 | LOC: Config.accessList.identLookup | |
1937 | DOC_START | |
1938 | A list of ACL elements which, if matched, cause an ident | |
1939 | (RFC 931) lookup to be performed for this request. For | |
1940 | example, you might choose to always perform ident lookups | |
1941 | for your main multi-user Unix boxes, but not for your Macs | |
1942 | and PCs. By default, ident lookups are not performed for | |
1943 | any requests. | |
1944 | ||
1945 | To enable ident lookups for specific client addresses, you | |
1946 | can follow this example: | |
1947 | ||
1948 | acl ident_aware_hosts src 198.168.1.0/255.255.255.0 | |
1949 | ident_lookup_access allow ident_aware_hosts | |
1950 | ident_lookup_access deny all | |
1951 | ||
1952 | This option may be disabled by using --disable-ident with | |
1953 | the configure script. | |
ec603b25 | 1954 | DOC_END |
1955 | ||
1956 | ||
0f74202c | 1957 | COMMENT_START |
3a278cb8 | 1958 | ADMINISTRATIVE PARAMETERS |
1959 | ----------------------------------------------------------------------------- | |
0f74202c | 1960 | COMMENT_END |
934b03fc | 1961 | |
1962 | NAME: cache_mgr | |
1963 | TYPE: string | |
1964 | DEFAULT: webmaster | |
1965 | LOC: Config.adminEmail | |
1966 | DOC_START | |
1967 | Email-address of local cache manager who will receive | |
1968 | mail if the cache dies. The default is "webmaster." | |
934b03fc | 1969 | DOC_END |
1970 | ||
1971 | ||
1972 | NAME: cache_effective_user | |
0153d498 | 1973 | TYPE: string |
a95856a0 | 1974 | DEFAULT: nobody |
0153d498 | 1975 | LOC: Config.effectiveUser |
1976 | DOC_NONE | |
1977 | ||
1978 | NAME: cache_effective_group | |
1979 | TYPE: string | |
8749fa47 | 1980 | DEFAULT: none |
0153d498 | 1981 | LOC: Config.effectiveGroup |
934b03fc | 1982 | DOC_START |
5a3f6538 | 1983 | |
934b03fc | 1984 | If the cache is run as root, it will change its effective/real |
5a3f6538 | 1985 | UID/GID to the UID/GID specified below. The default is to |
8749fa47 | 1986 | change to UID to nobody and GID to the default group of nobody. |
5a3f6538 | 1987 | |
1988 | If Squid is not started as root, the default is to keep the | |
8749fa47 | 1989 | current UID/GID, and only the GID can be changed to any of |
1990 | the groups the user starting Squid is member of. Note that if | |
1991 | Squid is not started as root then you cannot set http_port to | |
1992 | a value lower than 1024. | |
934b03fc | 1993 | DOC_END |
1994 | ||
1995 | ||
1996 | NAME: visible_hostname | |
1997 | TYPE: string | |
1998 | LOC: Config.visibleHostname | |
f1dc9b30 | 1999 | DEFAULT: none |
934b03fc | 2000 | DOC_START |
2001 | If you want to present a special hostname in error messages, etc, | |
2002 | then define this. Otherwise, the return value of gethostname() | |
cf5cc17e | 2003 | will be used. If you have multiple caches in a cluster and |
2004 | get errors about IP-forwarding you must set them to have individual | |
2005 | names with this setting. | |
934b03fc | 2006 | DOC_END |
2007 | ||
98829f69 | 2008 | |
2009 | NAME: unique_hostname | |
2010 | TYPE: string | |
2011 | LOC: Config.uniqueHostname | |
2012 | DEFAULT: none | |
2013 | DOC_START | |
2014 | If you want to have multiple machines with the same | |
2015 | 'visible_hostname' then you must give each machine a different | |
2016 | 'unique_hostname' so that forwarding loops can be detected. | |
98829f69 | 2017 | DOC_END |
2018 | ||
1f38f50a | 2019 | |
2020 | NAME: hostname_aliases | |
2021 | TYPE: wordlist | |
2022 | LOC: Config.hostnameAliases | |
2023 | DEFAULT: none | |
2024 | DOC_START | |
2025 | A list of other DNS names that your cache has. | |
2026 | DOC_END | |
2027 | ||
0f74202c | 2028 | COMMENT_START |
3a278cb8 | 2029 | OPTIONS FOR THE CACHE REGISTRATION SERVICE |
2030 | ----------------------------------------------------------------------------- | |
934b03fc | 2031 | |
3a278cb8 | 2032 | This section contains parameters for the (optional) cache |
2033 | announcement service. This service is provided to help | |
2034 | cache administrators locate one another in order to join or | |
2035 | create cache hierarchies. | |
934b03fc | 2036 | |
3a278cb8 | 2037 | An 'announcement' message is sent (via UDP) to the registration |
efd900cb | 2038 | service by Squid. By default, the announcement message is NOT |
d2d631ce | 2039 | SENT unless you enable it with 'announce_period' below. |
3a278cb8 | 2040 | |
2041 | The announcement message includes your hostname, plus the | |
2042 | following information from this configuration file: | |
934b03fc | 2043 | |
3a278cb8 | 2044 | http_port |
2045 | icp_port | |
2046 | cache_mgr | |
2047 | ||
2048 | All current information is processed regularly and made | |
2b6662ba | 2049 | available on the Web at http://www.ircache.net/Cache/Tracker/. |
0f74202c | 2050 | COMMENT_END |
934b03fc | 2051 | |
f1dc9b30 | 2052 | NAME: announce_period |
2053 | TYPE: time_t | |
2054 | LOC: Config.Announce.period | |
d2d631ce | 2055 | DEFAULT: 0 |
934b03fc | 2056 | DOC_START |
d2d631ce | 2057 | This is how frequently to send cache announcements. The |
2058 | default is `0' which disables sending the announcement | |
2059 | messages. | |
934b03fc | 2060 | |
cd748f27 | 2061 | To enable announcing your cache, just uncomment the line |
2062 | below. | |
2063 | ||
6b53c392 | 2064 | NOCOMMENT_START |
2065 | #To enable announcing your cache, just uncomment the line below. | |
2066 | #announce_period 1 day | |
2067 | NOCOMMENT_END | |
934b03fc | 2068 | DOC_END |
2069 | ||
2070 | ||
f1dc9b30 | 2071 | NAME: announce_host |
2072 | TYPE: string | |
61735fcf | 2073 | DEFAULT: tracker.ircache.net |
f1dc9b30 | 2074 | LOC: Config.Announce.host |
2075 | DOC_NONE | |
2076 | ||
cf5cc17e | 2077 | NAME: announce_file |
2078 | TYPE: string | |
61735fcf | 2079 | DEFAULT: none |
cf5cc17e | 2080 | LOC: Config.Announce.file |
2081 | DOC_NONE | |
2082 | ||
f1dc9b30 | 2083 | NAME: announce_port |
2084 | TYPE: ushort | |
2085 | DEFAULT: 3131 | |
2086 | LOC: Config.Announce.port | |
934b03fc | 2087 | DOC_START |
d2d631ce | 2088 | announce_host and announce_port set the hostname and port |
2089 | number where the registration message will be sent. | |
934b03fc | 2090 | |
d2d631ce | 2091 | Hostname will default to 'tracker.ircache.net' and port will |
2092 | default default to 3131. If the 'filename' argument is given, | |
2093 | the contents of that file will be included in the announce | |
2094 | message. | |
934b03fc | 2095 | DOC_END |
2096 | ||
0f74202c | 2097 | COMMENT_START |
3a278cb8 | 2098 | HTTPD-ACCELERATOR OPTIONS |
2099 | ----------------------------------------------------------------------------- | |
0f74202c | 2100 | COMMENT_END |
934b03fc | 2101 | |
f1dc9b30 | 2102 | NAME: httpd_accel_host |
2103 | TYPE: string | |
2104 | LOC: Config.Accel.host | |
2105 | DEFAULT: none | |
2106 | DOC_NONE | |
2107 | ||
2108 | NAME: httpd_accel_port | |
2109 | TYPE: ushort | |
2110 | LOC: Config.Accel.port | |
5b68a4d3 | 2111 | DEFAULT: 80 |
934b03fc | 2112 | DOC_START |
cf5cc17e | 2113 | If you want to run Squid as an httpd accelerator, define the |
934b03fc | 2114 | host name and port number where the real HTTP server is. |
2115 | ||
2116 | If you want virtual host support then specify the hostname | |
2117 | as "virtual". | |
2118 | ||
42b51993 | 2119 | If you want virtual port support then specify the port as "0". |
2120 | ||
839491ad | 2121 | NOTE: enabling httpd_accel_host disables proxy-caching and |
2122 | ICP. If you want these features enabled also, then set | |
2123 | the 'httpd_accel_with_proxy' option. | |
934b03fc | 2124 | DOC_END |
2125 | ||
13c7936a | 2126 | NAME: httpd_accel_single_host |
2127 | COMMENT: on|off | |
2128 | TYPE: onoff | |
2129 | LOC: Config.Accel.single_host | |
b0a9b5f2 | 2130 | DEFAULT: off |
13c7936a | 2131 | DOC_START |
2132 | If you are running Squid as a accelerator and have a single backend | |
2133 | server then set this to on. This causes Squid to forward the request | |
2134 | to this server irregardles of what any redirectors or Host headers | |
2135 | says. | |
2136 | ||
b0a9b5f2 | 2137 | Leave this at off if you have multiple backend servers, and use a |
2138 | redirector (or host table or private DNS) to map the requests to the | |
13c7936a | 2139 | appropriate backend servers. Note that the mapping needs to be a |
2140 | 1-1 mapping between requested and backend (from redirector) domain | |
2141 | names or caching will fail, as cacing is performed using the | |
2142 | URL returned from the redirector. | |
2143 | ||
2144 | See also redirect_rewrites_host_header. | |
2145 | DOC_END | |
934b03fc | 2146 | |
2147 | NAME: httpd_accel_with_proxy | |
2148 | COMMENT: on|off | |
2149 | TYPE: onoff | |
f1dc9b30 | 2150 | DEFAULT: off |
17a0a4ee | 2151 | LOC: Config.onoff.accel_with_proxy |
934b03fc | 2152 | DOC_START |
cf5cc17e | 2153 | If you want to use Squid as both a local httpd accelerator |
6b53c392 | 2154 | and as a proxy, change this to 'on'. Note however that your |
2155 | proxy users may have trouble to reach the accelerated domains | |
2156 | unless their browsers are configured not to use this proxy for | |
2157 | those domains (for example via the no_proxy browser configuration | |
2158 | setting) | |
934b03fc | 2159 | DOC_END |
2160 | ||
934b03fc | 2161 | NAME: httpd_accel_uses_host_header |
2162 | COMMENT: on|off | |
2163 | TYPE: onoff | |
f1dc9b30 | 2164 | DEFAULT: off |
934b03fc | 2165 | LOC: opt_accel_uses_host |
2166 | DOC_START | |
2167 | HTTP/1.1 requests include a Host: header which is basically the | |
2168 | hostname from the URL. Squid can be an accelerator for | |
2169 | different HTTP servers by looking at this header. However, | |
2170 | Squid does NOT check the value of the Host header, so it opens | |
2171 | a big security hole. We recommend that this option remain | |
2172 | disabled unless you are sure of what you are doing. | |
2173 | ||
04f6f348 | 2174 | However, you will need to enable this option if you run Squid |
2175 | as a transparent proxy. Otherwise, virtual servers which | |
2176 | require the Host: header will not be properly cached. | |
934b03fc | 2177 | DOC_END |
2178 | ||
0f74202c | 2179 | COMMENT_START |
3a278cb8 | 2180 | MISCELLANEOUS |
2181 | ----------------------------------------------------------------------------- | |
0f74202c | 2182 | COMMENT_END |
934b03fc | 2183 | |
2184 | NAME: dns_testnames | |
2185 | TYPE: wordlist | |
2186 | LOC: Config.dns_testname_list | |
f1dc9b30 | 2187 | DEFAULT: none |
6b53c392 | 2188 | DEFAULT_IF_NONE: netscape.com internic.net nlanr.net microsoft.com |
934b03fc | 2189 | DOC_START |
2190 | The DNS tests exit as soon as the first site is successfully looked up | |
2191 | ||
6b53c392 | 2192 | This test can be disabled with the -D command line option. |
934b03fc | 2193 | DOC_END |
2194 | ||
2195 | ||
2196 | NAME: logfile_rotate | |
2197 | TYPE: int | |
2198 | DEFAULT: 10 | |
2199 | LOC: Config.Log.rotateNumber | |
2200 | DOC_START | |
5a3f6538 | 2201 | Specifies the number of logfile rotations to make when you |
2202 | type 'squid -k rotate'. The default is 10, which will rotate | |
cf5cc17e | 2203 | with extensions 0 through 9. Setting logfile_rotate to 0 will |
934b03fc | 2204 | disable the rotation, but the logfiles are still closed and |
cf5cc17e | 2205 | re-opened. This will enable you to rename the logfiles |
5a3f6538 | 2206 | yourself just before sending the rotate signal. |
2207 | ||
2208 | Note, the 'squid -k rotate' command normally sends a USR1 | |
2209 | signal to the running squid process. In certain situations | |
2210 | (e.g. on Linux with Async I/O), USR1 is used for other | |
2211 | purposes, so -k rotate uses another signal. It is best to get | |
2212 | in the habit of using 'squid -k rotate' instead of 'kill -USR1 | |
2213 | <pid>'. | |
934b03fc | 2214 | DOC_END |
2215 | ||
2216 | ||
2217 | NAME: append_domain | |
f1dc9b30 | 2218 | TYPE: string |
2219 | LOC: Config.appendDomain | |
2220 | DEFAULT: none | |
934b03fc | 2221 | DOC_START |
cf5cc17e | 2222 | Appends local domain name to hostnames without any dots in |
2223 | them. append_domain must begin with a period. | |
934b03fc | 2224 | |
6b53c392 | 2225 | Example: |
2226 | append_domain .yourdomain.com | |
934b03fc | 2227 | DOC_END |
2228 | ||
2229 | ||
2230 | NAME: tcp_recv_bufsize | |
89de058c | 2231 | COMMENT: (bytes) |
1b635117 | 2232 | TYPE: b_size_t |
89de058c | 2233 | DEFAULT: 0 bytes |
934b03fc | 2234 | LOC: Config.tcpRcvBufsz |
2235 | DOC_START | |
2236 | Size of receive buffer to set for TCP sockets. Probably just | |
2237 | as easy to change your kernel's default. Set to zero to use | |
2238 | the default buffer size. | |
934b03fc | 2239 | DOC_END |
2240 | ||
934b03fc | 2241 | NAME: err_html_text |
f1dc9b30 | 2242 | TYPE: eol |
2243 | LOC: Config.errHtmlText | |
2244 | DEFAULT: none | |
934b03fc | 2245 | DOC_START |
2246 | HTML text to include in error messages. Make this a "mailto" | |
2247 | URL to your admin address, or maybe just a link to your | |
2248 | organizations Web page. | |
2249 | ||
ab1e6b8a | 2250 | To include this in your error messages, you must rewrite |
2251 | the error template files (found in the "errors" directory). | |
2252 | Wherever you want the 'err_html_text' line to appear, | |
2253 | insert a %L tag in the error template file. | |
934b03fc | 2254 | DOC_END |
2255 | ||
2256 | ||
2257 | NAME: deny_info | |
2258 | TYPE: denyinfo | |
2259 | LOC: Config.denyInfoList | |
f1dc9b30 | 2260 | DEFAULT: none |
934b03fc | 2261 | DOC_START |
02922e76 | 2262 | Usage: deny_info err_page_name acl |
2263 | Example: deny_info ERR_CUSTOM_ACCESS_DENIED bad_guys | |
934b03fc | 2264 | |
02922e76 | 2265 | This can be used to return a ERR_ page for requests which |
934b03fc | 2266 | do not pass the 'http_access' rules. A single ACL will cause |
2267 | the http_access check to fail. If a 'deny_info' line exists | |
02922e76 | 2268 | for that ACL then Squid returns a corresponding error page. |
cf5cc17e | 2269 | |
02922e76 | 2270 | You may use ERR_ pages that come with Squid or create your own pages |
2271 | and put them into the configured errors/ directory. | |
934b03fc | 2272 | DOC_END |
2273 | ||
934b03fc | 2274 | NAME: memory_pools |
2275 | COMMENT: on|off | |
2276 | TYPE: onoff | |
f1dc9b30 | 2277 | DEFAULT: on |
3f6c0fb2 | 2278 | LOC: Config.onoff.mem_pools |
934b03fc | 2279 | DOC_START |
2280 | If set, Squid will keep pools of allocated (but unused) memory | |
2281 | available for future use. If memory is a premium on your | |
7021844c | 2282 | system and you believe your malloc library outperforms Squid |
d0d41f07 | 2283 | routines, disable this. |
934b03fc | 2284 | DOC_END |
2285 | ||
7021844c | 2286 | NAME: memory_pools_limit |
2287 | COMMENT: (bytes) | |
2288 | TYPE: b_size_t | |
2289 | DEFAULT: none | |
f12c295b | 2290 | LOC: Config.MemPools.limit |
7021844c | 2291 | DOC_START |
f12c295b | 2292 | Used only with memory_pools on: |
2293 | memory_pools_limit 50 MB | |
7021844c | 2294 | |
f12c295b | 2295 | If set to a non-zero value, Squid will keep at most the specified |
2296 | limit of allocated (but unused) memory in memory pools. All free() | |
2297 | requests that exceed this limit will be handled by your malloc | |
2298 | library. Squid does not pre-allocate any memory, just safe-keeps | |
2299 | objects that otherwise would be free()d. Thus, it is safe to set | |
7021844c | 2300 | memory_pools_limit to a reasonably high value even if your |
f12c295b | 2301 | configuration will use less memory. |
2302 | ||
2303 | If not set (default) or set to zero, Squid will keep all memory it | |
2304 | can. That is, there will be no limit on the total amount of memory | |
2305 | used for safe-keeping. | |
7021844c | 2306 | |
2307 | To disable memory allocation optimization, do not set | |
2308 | memory_pools_limit to 0. Set memory_pools to "off" instead. | |
2309 | ||
f12c295b | 2310 | An overhead for maintaining memory pools is not taken into account |
2311 | when the limit is checked. This overhead is close to four bytes per | |
2312 | object kept. However, pools may actually _save_ memory because of | |
2313 | reduced memory thrashing in your malloc library. | |
7021844c | 2314 | DOC_END |
2315 | ||
934b03fc | 2316 | NAME: forwarded_for |
2317 | COMMENT: on|off | |
2318 | TYPE: onoff | |
f1dc9b30 | 2319 | DEFAULT: on |
934b03fc | 2320 | LOC: opt_forwarded_for |
2321 | DOC_START | |
2322 | If set, Squid will include your system's IP address or name | |
2323 | in the HTTP requests it forwards. By default it looks like | |
2324 | this: | |
2325 | ||
2326 | X-Forwarded-For: 192.1.2.3 | |
2327 | ||
2328 | If you disable this, it will appear as | |
2329 | ||
2330 | X-Forwarded-For: unknown | |
934b03fc | 2331 | DOC_END |
2332 | ||
2333 | NAME: log_icp_queries | |
2334 | COMMENT: on|off | |
2335 | TYPE: onoff | |
f1dc9b30 | 2336 | DEFAULT: on |
17a0a4ee | 2337 | LOC: Config.onoff.log_udp |
934b03fc | 2338 | DOC_START |
cf5cc17e | 2339 | If set, ICP queries are logged to access.log. You may wish |
2340 | do disable this if your ICP load is VERY high to speed things | |
2341 | up or to simplify log analysis. | |
934b03fc | 2342 | DOC_END |
2343 | ||
88738790 | 2344 | NAME: icp_hit_stale |
2345 | COMMENT: on|off | |
2346 | TYPE: onoff | |
2347 | DEFAULT: off | |
17a0a4ee | 2348 | LOC: Config.onoff.icp_hit_stale |
88738790 | 2349 | DOC_START |
2350 | If you want to return ICP_HIT for stale cache objects, set this | |
2351 | option to 'on'. If you have sibling relationships with caches | |
2352 | in other administrative domains, this should be 'off'. If you only | |
2353 | have sibling relationships with caches under your control, then | |
2354 | it is probably okay to set this to 'on'. | |
88738790 | 2355 | DOC_END |
2356 | ||
934b03fc | 2357 | |
2358 | NAME: minimum_direct_hops | |
2359 | TYPE: int | |
2360 | DEFAULT: 4 | |
2361 | LOC: Config.minDirectHops | |
2362 | DOC_START | |
2363 | If using the ICMP pinging stuff, do direct fetches for sites | |
2364 | which are no more than this many hops away. | |
934b03fc | 2365 | DOC_END |
2366 | ||
5f84d830 | 2367 | NAME: minimum_direct_rtt |
2368 | TYPE: int | |
2369 | DEFAULT: 400 | |
2370 | LOC: Config.minDirectRtt | |
2371 | DOC_START | |
2372 | If using the ICMP pinging stuff, do direct fetches for sites | |
2373 | which are no more than this many rtt milliseconds away. | |
2374 | DOC_END | |
934b03fc | 2375 | |
2376 | NAME: cachemgr_passwd | |
2377 | TYPE: cachemgrpasswd | |
86101e40 | 2378 | DEFAULT: none |
f1dc9b30 | 2379 | LOC: Config.passwd_list |
934b03fc | 2380 | DOC_START |
2381 | Specify passwords for cachemgr operations. | |
2382 | ||
2383 | Usage: cachemgr_passwd password action action ... | |
2384 | ||
064a674d | 2385 | Some valid actions are (see cache manager menu for a full list): |
2386 | 5min | |
2387 | 60min | |
2388 | asndb | |
2389 | authenticator | |
2390 | cbdata | |
2391 | client_list | |
2392 | comm_incoming | |
2393 | config * | |
2394 | counters | |
2395 | delay | |
2396 | digest_stats | |
cf5cc17e | 2397 | dns |
064a674d | 2398 | events |
cf5cc17e | 2399 | filedescriptors |
064a674d | 2400 | fqdncache |
2401 | histograms | |
2402 | http_headers | |
2403 | info | |
2404 | io | |
2405 | ipcache | |
2406 | mem | |
2407 | menu | |
cf5cc17e | 2408 | netdb |
064a674d | 2409 | non_peers |
2410 | objects | |
2411 | pconn | |
2412 | peer_select | |
2413 | redirector | |
2414 | refresh | |
934b03fc | 2415 | server_list |
064a674d | 2416 | shutdown * |
2417 | store_digest | |
2418 | storedir | |
2419 | utilization | |
2420 | via_headers | |
2421 | vm_objects | |
934b03fc | 2422 | |
2423 | * Indicates actions which will not be performed without a | |
2424 | valid password, others can be performed if not listed here. | |
2425 | ||
2426 | To disable an action, set the password to "disable". | |
2427 | To allow performing an action without a password, set the | |
2428 | password to "none". | |
2429 | ||
2430 | Use the keyword "all" to set the same password for all actions. | |
2431 | ||
6b53c392 | 2432 | Example: |
2433 | cachemgr_passwd secret shutdown | |
2434 | cachemgr_passwd lesssssssecret info stats/objects | |
2435 | cachemgr_passwd disable all | |
934b03fc | 2436 | DOC_END |
2437 | ||
934b03fc | 2438 | NAME: store_avg_object_size |
86101e40 | 2439 | COMMENT: (kbytes) |
2440 | TYPE: kb_size_t | |
2bf99296 | 2441 | DEFAULT: 13 KB |
934b03fc | 2442 | LOC: Config.Store.avgObjectSize |
2443 | DOC_START | |
2444 | Average object size, used to estimate number of objects your | |
2445 | cache can hold. See doc/Release-Notes-1.1.txt. The default is | |
2bf99296 | 2446 | 13 KB. |
934b03fc | 2447 | DOC_END |
2448 | ||
2449 | NAME: store_objects_per_bucket | |
2450 | TYPE: int | |
baf144ad | 2451 | DEFAULT: 20 |
934b03fc | 2452 | LOC: Config.Store.objectsPerBucket |
2453 | DOC_START | |
2454 | Target number of objects per bucket in the store hash table. | |
2455 | Lowering this value increases the total number of buckets and | |
7e3ce7b9 | 2456 | also the storage maintenance rate. The default is 50. |
934b03fc | 2457 | DOC_END |
2458 | ||
934b03fc | 2459 | NAME: client_db |
2460 | COMMENT: on|off | |
2461 | TYPE: onoff | |
f1dc9b30 | 2462 | DEFAULT: on |
17a0a4ee | 2463 | LOC: Config.onoff.client_db |
934b03fc | 2464 | DOC_START |
2465 | If you want to disable collecting per-client statistics, then | |
2466 | turn off client_db here. | |
934b03fc | 2467 | DOC_END |
2468 | ||
2469 | ||
2470 | NAME: netdb_low | |
2471 | TYPE: int | |
2472 | DEFAULT: 900 | |
2473 | LOC: Config.Netdb.low | |
2474 | DOC_NONE | |
2475 | ||
2476 | NAME: netdb_high | |
2477 | TYPE: int | |
2478 | DEFAULT: 1000 | |
2479 | LOC: Config.Netdb.high | |
2480 | DOC_START | |
2481 | The low and high water marks for the ICMP measurement | |
2482 | database. These are counts, not percents. The defaults are | |
2483 | 900 and 1000. When the high water mark is reached, database | |
2484 | entries will be deleted until the low mark is reached. | |
934b03fc | 2485 | DOC_END |
2486 | ||
2487 | ||
2488 | NAME: netdb_ping_period | |
f1dc9b30 | 2489 | TYPE: time_t |
934b03fc | 2490 | LOC: Config.Netdb.period |
9e975e4e | 2491 | DEFAULT: 5 minutes |
934b03fc | 2492 | DOC_START |
2493 | The minimum period for measuring a site. There will be at | |
2494 | least this much delay between successive pings to the same | |
2495 | network. The default is five minutes. | |
934b03fc | 2496 | DOC_END |
2497 | ||
2498 | ||
2499 | NAME: query_icmp | |
2500 | COMMENT: on|off | |
2501 | TYPE: onoff | |
f1dc9b30 | 2502 | DEFAULT: off |
17a0a4ee | 2503 | LOC: Config.onoff.query_icmp |
934b03fc | 2504 | DOC_START |
2505 | If you want to ask your peers to include ICMP data in their ICP | |
2506 | replies, enable this option. | |
2507 | ||
cf5cc17e | 2508 | If your peer has configured Squid (during compilation) with |
2509 | '--enable-icmp' then that peer will send ICMP pings to origin server | |
2510 | sites of the URLs it receives. If you enable this option then the | |
2511 | ICP replies from that peer will include the ICMP data (if available). | |
2512 | Then, when choosing a parent cache, Squid will choose the parent with | |
934b03fc | 2513 | the minimal RTT to the origin server. When this happens, the |
2514 | hierarchy field of the access.log will be | |
2515 | "CLOSEST_PARENT_MISS". This option is off by default. | |
934b03fc | 2516 | DOC_END |
2517 | ||
88500f96 | 2518 | NAME: test_reachability |
194dd3b8 | 2519 | COMMENT: on|off |
2520 | TYPE: onoff | |
2521 | DEFAULT: off | |
2522 | LOC: Config.onoff.test_reachability | |
2523 | DOC_START | |
2524 | When this is 'on', ICP MISS replies will be ICP_MISS_NOFETCH | |
2525 | instead of ICP_MISS if the target host is NOT in the ICMP | |
2526 | database, or has a zero RTT. | |
194dd3b8 | 2527 | DOC_END |
2528 | ||
78f1250a | 2529 | NAME: buffered_logs |
2530 | COMMENT: on|off | |
2531 | TYPE: onoff | |
2532 | DEFAULT: off | |
17a0a4ee | 2533 | LOC: Config.onoff.buffered_logs |
78f1250a | 2534 | DOC_START |
2535 | Some log files (cache.log, useragent.log) are written with | |
2536 | stdio functions, and as such they can be buffered or | |
cf5cc17e | 2537 | unbuffered. By default they will be unbuffered. Buffering them |
2538 | can speed up the writing slightly (though you are unlikely to | |
2539 | need to worry). | |
78f1250a | 2540 | DOC_END |
2541 | ||
465dc415 | 2542 | NAME: reload_into_ims |
9f60cfdf | 2543 | IFDEF: HTTP_VIOLATIONS |
465dc415 | 2544 | COMMENT: on|off |
2545 | TYPE: onoff | |
2546 | DEFAULT: off | |
2547 | LOC: Config.onoff.reload_into_ims | |
2548 | DOC_START | |
2549 | When you enable this option, client no-cache or ``reload'' | |
2550 | requests will be changed to If-Modified-Since requests. | |
2551 | Doing this VIOLATES the HTTP standard. Enabling this | |
2552 | feature could make you liable for problems which it | |
2553 | causes. | |
cbe3a719 | 2554 | |
2555 | see also refresh_pattern for a more selective approach. | |
2556 | ||
6b8e7481 | 2557 | This option may be disabled by using --disable-http-violations |
2558 | with the configure script. | |
465dc415 | 2559 | DOC_END |
2560 | ||
934b03fc | 2561 | NAME: always_direct |
2562 | TYPE: acl_access | |
2563 | LOC: Config.accessList.AlwaysDirect | |
f1dc9b30 | 2564 | DEFAULT: none |
934b03fc | 2565 | DOC_START |
2a78fa67 | 2566 | Usage: always_direct allow|deny [!]aclname ... |
2567 | ||
2568 | Here you can use ACL elements to specify requests which should | |
3445a83a | 2569 | ALWAYS be forwarded directly to origin servers. For example, |
2570 | to always directly forward requests for local servers use | |
2a78fa67 | 2571 | something like: |
2572 | ||
2573 | acl local-servers dstdomain my.domain.net | |
2574 | always_direct allow local-servers | |
2575 | ||
2576 | To always forward FTP requests directly, use | |
2577 | ||
2578 | acl FTP proto FTP | |
2579 | always_direct allow FTP | |
2580 | ||
2581 | NOTE: There is a similar, but opposite option named | |
2582 | 'never_direct'. You need to be aware that "always_direct deny | |
2583 | foo" is NOT the same thing as "never_direct allow foo". You | |
2584 | may need to use a deny rule to exclude a more-specific case of | |
2585 | some other rule. Example: | |
2586 | ||
2587 | acl local-external dstdomain external.foo.net | |
2588 | acl local-servers dstdomain foo.net | |
2589 | always_direct deny local-external | |
2590 | always_direct allow local-servers | |
3445a83a | 2591 | |
2592 | This option replaces some v1.1 options such as local_domain | |
2593 | and local_ip. | |
934b03fc | 2594 | DOC_END |
2595 | ||
2596 | NAME: never_direct | |
2597 | TYPE: acl_access | |
2598 | LOC: Config.accessList.NeverDirect | |
f1dc9b30 | 2599 | DEFAULT: none |
934b03fc | 2600 | DOC_START |
d0d41f07 | 2601 | Usage: never_direct allow|deny [!]aclname ... |
2a78fa67 | 2602 | |
2603 | never_direct is the opposite of always_direct. Please read | |
2604 | the description for always_direct if you have not already. | |
934b03fc | 2605 | |
2a78fa67 | 2606 | With 'never_direct' you can use ACL elements to specify |
2607 | requests which should NEVER be forwarded directly to origin | |
3445a83a | 2608 | servers. For example, to force the use of a proxy for all |
2609 | requests, except those in your local domain use something like: | |
2a78fa67 | 2610 | |
3445a83a | 2611 | acl local-servers dstdomain foo.net |
2a78fa67 | 2612 | acl all src 0.0.0.0/0.0.0.0 |
d0d41f07 | 2613 | never_direct deny local-servers |
2614 | never_direct allow all | |
3445a83a | 2615 | |
2616 | or if squid is inside a firewall and there is local intranet | |
2617 | servers inside the firewall then use something like: | |
2618 | ||
2619 | acl local-intranet dstdomain foo.net | |
2620 | acl local-external dstdomain external.foo.net | |
2621 | always_direct deny local-external | |
2622 | always_direct allow local-intranet | |
2623 | never_direct allow all | |
2624 | ||
2625 | This option replaces some v1.1 options such as inside_firewall | |
2626 | and firewall_ip. | |
2a78fa67 | 2627 | DOC_END |
934b03fc | 2628 | |
6bccf575 | 2629 | NAME: header_access |
2630 | TYPE: http_header_access[] | |
2631 | LOC: Config.header_access | |
97474590 | 2632 | DEFAULT: none |
2633 | DOC_START | |
6bccf575 | 2634 | Usage: header_access header_name allow|deny [!]aclname ... |
2635 | ||
2636 | This option replaces the old 'anonymize_headers' and the | |
2637 | older 'http_anonymizer' option with something that is much | |
2638 | more configurable. This new method creates a list of ACLs | |
2639 | for each header, allowing you very fine-tuned header | |
2640 | mangling. | |
2641 | ||
2642 | You can only specify known headers for the header name. | |
2643 | Other headers are reclassified as 'Other'. You can also | |
2644 | refer to all the headers with 'All'. | |
2645 | ||
2646 | For example, to achieve the same behaviour as the old | |
5bcad01d | 2647 | 'http_anonymizer standard' option, you should use: |
6bccf575 | 2648 | |
2649 | header_access From deny all | |
2650 | header_access Referer deny all | |
2651 | header_access Server deny all | |
2652 | header_access User-Agent deny all | |
2653 | header_access WWW-Authenticate deny all | |
2654 | header_access Link deny all | |
97474590 | 2655 | |
5bcad01d | 2656 | Or, to reproduce the old 'http_anonymizer paranoid' feature |
2657 | you should use: | |
6bccf575 | 2658 | |
2659 | header_access Allow allow all | |
2660 | header_access Authorization allow all | |
2661 | header_access Cache-Control allow all | |
2662 | header_access Content-Encoding allow all | |
2663 | header_access Content-Length allow all | |
2664 | header_access Content-Type allow all | |
2665 | header_access Date allow all | |
2666 | header_access Expires allow all | |
2667 | header_access Host allow all | |
2668 | header_access If-Modified-Since allow all | |
2669 | header_access Last-Modified allow all | |
2670 | header_access Location allow all | |
2671 | header_access Pragma allow all | |
2672 | header_access Accept allow all | |
2673 | header_access Charset allow all | |
2674 | header_access Accept-Encoding allow all | |
2675 | header_access Accept-Language allow all | |
2676 | header_access Content-Language allow all | |
2677 | header_access Mime-Version allow all | |
2678 | header_access Retry-After allow all | |
2679 | header_access Title allow all | |
2680 | header_access Connection allow all | |
2681 | header_access Proxy-Connection allow all | |
2682 | header_access All deny all | |
2683 | ||
5bcad01d | 2684 | By default, all headers are allowed (no anonymizing is |
2685 | performed). | |
97474590 | 2686 | DOC_END |
2687 | ||
6bccf575 | 2688 | NAME: header_replace |
2689 | TYPE: http_header_replace[] | |
2690 | LOC: Config.header_access | |
88738790 | 2691 | DEFAULT: none |
2692 | DOC_START | |
6bccf575 | 2693 | Usage: header_replace header_name message |
2694 | Example: header_replace User-Agent Nutscrape/1.0 (CP/M; 8-bit) | |
2695 | ||
2696 | This option allows you to change the contents of headers | |
2697 | denied with header_access above, by replacing them with | |
2698 | some fixed string. This replaces the old fake_user_agent | |
2699 | option. | |
2700 | ||
2701 | By default, headers are removed if denied. | |
88738790 | 2702 | DOC_END |
2703 | ||
365cb147 | 2704 | NAME: icon_directory |
f0b19334 | 2705 | TYPE: string |
365cb147 | 2706 | LOC: Config.icons.directory |
2707 | DEFAULT: @DEFAULT_ICON_DIR@ | |
2708 | DOC_START | |
cf5cc17e | 2709 | Where the icons are stored. These are normally kept in |
2710 | @DEFAULT_ICON_DIR@ | |
365cb147 | 2711 | DOC_END |
2712 | ||
cf5cc17e | 2713 | NAME: error_directory |
365cb147 | 2714 | TYPE: string |
cf5cc17e | 2715 | LOC: Config.errorDirectory |
2716 | DEFAULT: @DEFAULT_ERROR_DIR@ | |
365cb147 | 2717 | DOC_START |
cf5cc17e | 2718 | If you wish to create your own versions of the default |
efd900cb | 2719 | (English) error files, either to customize them to suit your |
2720 | language or company copy the template English files to another | |
cf5cc17e | 2721 | directory and point this tag at them. |
365cb147 | 2722 | DOC_END |
88738790 | 2723 | |
22c653cd | 2724 | NAME: minimum_retry_timeout |
2725 | COMMENT: (seconds) | |
2726 | TYPE: time_t | |
2727 | LOC: Config.retry.timeout | |
2728 | DEFAULT: 5 seconds | |
2729 | DOC_START | |
2730 | This specifies the minimum connect timeout, for when the | |
2731 | connect timeout is reduced to compensate for the availability | |
2732 | of multiple IP addresses. | |
2733 | ||
cf5cc17e | 2734 | When a connection to a host is initiated, and that host has |
2735 | several IP addresses, the default connection timeout is reduced | |
2736 | by dividing it by the number of addresses. So, a site with 15 | |
2737 | addresses would then have a timeout of 8 seconds for each | |
2738 | address attempted. To avoid having the timeout reduced to the | |
2739 | point where even a working host would not have a chance to | |
2740 | respond, this setting is provided. The default, and the | |
2741 | minimum value, is five seconds, and the maximum value is sixty | |
2742 | seconds, or half of connect_timeout, whichever is greater and | |
2743 | less than connect_timeout. | |
22c653cd | 2744 | DOC_END |
2745 | ||
2746 | NAME: maximum_single_addr_tries | |
2747 | TYPE: int | |
2748 | LOC: Config.retry.maxtries | |
2749 | DEFAULT: 3 | |
2750 | DOC_START | |
2751 | This sets the maximum number of connection attempts for a | |
2752 | host that only has one address (for multiple-address hosts, | |
2753 | each address is tried once). | |
2754 | ||
2755 | The default value is three tries, the (not recommended) | |
2756 | maximum is 255 tries. A warning message will be generated | |
2757 | if it is set to a value greater than ten. | |
22c653cd | 2758 | DOC_END |
6d1c0d53 | 2759 | |
a97cfa48 | 2760 | NAME: snmp_port |
2761 | TYPE: ushort | |
2762 | LOC: Config.Port.snmp | |
2763 | DEFAULT: 3401 | |
1df370e3 | 2764 | IFDEF: SQUID_SNMP |
a97cfa48 | 2765 | DOC_START |
cf5cc17e | 2766 | Squid can now serve statistics and status information via SNMP. |
2767 | By default it listens to port 3401 on the machine. If you don't | |
9bc73deb | 2768 | wish to use SNMP, set this to "0". |
cf5cc17e | 2769 | |
2770 | NOTE: SNMP support requires use the --enable-snmp configure | |
2771 | command line option. | |
a97cfa48 | 2772 | DOC_END |
2773 | ||
dba79ac5 | 2774 | NAME: snmp_access |
2775 | TYPE: acl_access | |
2776 | LOC: Config.accessList.snmp | |
a97cfa48 | 2777 | DEFAULT: none |
6502682e | 2778 | DEFAULT_IF_NONE: deny all |
1df370e3 | 2779 | IFDEF: SQUID_SNMP |
a97cfa48 | 2780 | DOC_START |
dba79ac5 | 2781 | Allowing or denying access to the SNMP port. |
08f6b5e0 | 2782 | |
2783 | All access to the agent is denied by default. | |
dba79ac5 | 2784 | usage: |
4feb7b2e | 2785 | |
dba79ac5 | 2786 | snmp_access allow|deny [!]aclname ... |
08f6b5e0 | 2787 | |
2788 | Example: | |
6b53c392 | 2789 | snmp_access allow snmppublic localhost |
2790 | snmp_access deny all | |
bdf18524 | 2791 | DOC_END |
2792 | ||
15dcc168 | 2793 | NAME: snmp_incoming_address |
2794 | TYPE: address | |
1ecaa0a0 | 2795 | LOC: Config.Addrs.snmp_incoming |
15dcc168 | 2796 | DEFAULT: 0.0.0.0 |
2797 | IFDEF: SQUID_SNMP | |
2798 | DOC_NONE | |
2799 | NAME: snmp_outgoing_address | |
2800 | TYPE: address | |
2801 | LOC: Config.Addrs.snmp_outgoing | |
2802 | DEFAULT: 255.255.255.255 | |
2803 | IFDEF: SQUID_SNMP | |
2804 | DOC_START | |
2805 | Just like 'udp_incoming_address' above, but for the SNMP port. | |
2806 | ||
2807 | snmp_incoming_address is used for the SNMP socket receiving | |
2808 | messages from SNMP agents. | |
2809 | snmp_outgoing_address is used for SNMP packets returned to SNMP | |
2810 | agents. | |
2811 | ||
6b53c392 | 2812 | The default snmp_incoming_address (0.0.0.0) is to listen on all |
2813 | available network interfaces. | |
15dcc168 | 2814 | |
6b53c392 | 2815 | If snmp_outgoing_address is set to 255.255.255.255 (the default) |
2816 | then it will use the same socket as snmp_incoming_address. Only | |
2817 | change this if you want to have SNMP replies sent using another | |
2818 | address than where this Squid listens for SNMP queries. | |
15dcc168 | 2819 | |
6b53c392 | 2820 | NOTE, snmp_incoming_address and snmp_outgoing_address can not have |
2821 | the same value since they both use port 3401. | |
15dcc168 | 2822 | DOC_END |
bdf18524 | 2823 | |
53ad48e6 | 2824 | NAME: as_whois_server |
2825 | TYPE: string | |
2826 | LOC: Config.as_whois_server | |
2827 | DEFAULT: whois.ra.net | |
2828 | DEFAULT_IF_NONE: whois.ra.net | |
2829 | DOC_START | |
cf5cc17e | 2830 | WHOIS server to query for AS numbers. NOTE: AS numbers are |
2831 | queried only when Squid starts up, not for every request. | |
53ad48e6 | 2832 | DOC_END |
95e36d02 | 2833 | |
320e9f36 | 2834 | NAME: wccp_router |
2835 | TYPE: address | |
2836 | LOC: Config.Wccp.router | |
2837 | DEFAULT: 0.0.0.0 | |
eb824054 | 2838 | IFDEF: USE_WCCP |
320e9f36 | 2839 | DOC_START |
efd900cb | 2840 | Use this option to define your WCCP ``home'' router for |
2841 | Squid. Setting the 'wccp_router' to 0.0.0.0 (the default) | |
2842 | disables WCCP. | |
320e9f36 | 2843 | DOC_END |
2844 | ||
d20b1cd0 | 2845 | NAME: wccp_version |
2846 | TYPE: int | |
2847 | LOC: Config.Wccp.version | |
2848 | DEFAULT: 4 | |
2849 | IFDEF: USE_WCCP | |
2850 | DOC_START | |
2851 | According to some users, Cisco IOS 11.2 only supports WCCP | |
2852 | version 3. If you're using that version of IOS, change | |
2853 | this value to 3. | |
2854 | DOC_END | |
2855 | ||
320e9f36 | 2856 | NAME: wccp_incoming_address |
2857 | TYPE: address | |
eb824054 | 2858 | LOC: Config.Wccp.incoming |
320e9f36 | 2859 | DEFAULT: 0.0.0.0 |
eb824054 | 2860 | IFDEF: USE_WCCP |
320e9f36 | 2861 | DOC_NONE |
2862 | NAME: wccp_outgoing_address | |
2863 | TYPE: address | |
eb824054 | 2864 | LOC: Config.Wccp.outgoing |
320e9f36 | 2865 | DEFAULT: 255.255.255.255 |
eb824054 | 2866 | IFDEF: USE_WCCP |
320e9f36 | 2867 | DOC_START |
efd900cb | 2868 | wccp_incoming_address Use this option if you require WCCP |
2869 | messages to be received on only one | |
2870 | interface. Do NOT use this option if | |
2871 | you're unsure how many interfaces you | |
2872 | have, or if you know you have only one | |
2873 | interface. | |
320e9f36 | 2874 | |
efd900cb | 2875 | wccp_outgoing_address Use this option if you require WCCP |
2876 | messages to be sent out on only one | |
2877 | interface. Do NOT use this option if | |
2878 | you're unsure how many interfaces you | |
2879 | have, or if you know you have only one | |
2880 | interface. | |
320e9f36 | 2881 | |
efd900cb | 2882 | The default behavior is to not bind to any specific address. |
320e9f36 | 2883 | |
2884 | NOTE, wccp_incoming_address and wccp_outgoing_address can not have | |
2885 | the same value since they both use port 2048. | |
320e9f36 | 2886 | DOC_END |
2887 | ||
2888 | ||
95e36d02 | 2889 | COMMENT_START |
2890 | DELAY POOL PARAMETERS (all require DELAY_POOLS compilation option) | |
2891 | ----------------------------------------------------------------------------- | |
95e36d02 | 2892 | COMMENT_END |
2893 | ||
59715b38 | 2894 | NAME: delay_pools |
2895 | TYPE: delay_pool_count | |
2896 | DEFAULT: 0 | |
95e36d02 | 2897 | IFDEF: DELAY_POOLS |
59715b38 | 2898 | LOC: Config.Delay |
95e36d02 | 2899 | DOC_START |
59715b38 | 2900 | This represents the number of delay pools to be used. For example, |
2901 | if you have one class 2 delay pool and one class 3 delays pool, you | |
2902 | have a total of 2 delay pools. | |
2903 | ||
6b8e7481 | 2904 | To enable this option, you must use --enable-delay-pools with the |
2905 | configure script. | |
95e36d02 | 2906 | DOC_END |
2907 | ||
59715b38 | 2908 | NAME: delay_class |
2909 | TYPE: delay_pool_class | |
95e36d02 | 2910 | DEFAULT: none |
2911 | IFDEF: DELAY_POOLS | |
59715b38 | 2912 | LOC: Config.Delay |
95e36d02 | 2913 | DOC_START |
59715b38 | 2914 | This defines the class of each delay pool. There must be exactly one |
2915 | delay_class line for each delay pool. For example, to define two | |
2916 | delay pools, one of class 2 and one of class 3, the settings above | |
2917 | and here would be: | |
2918 | ||
6b53c392 | 2919 | Example: |
2920 | delay_pools 2 # 2 delay pools | |
2921 | delay_class 1 2 # pool 1 is a class 2 pool | |
2922 | delay_class 2 3 # pool 2 is a class 3 pool | |
59715b38 | 2923 | |
2924 | The delay pool classes are: | |
2925 | ||
2926 | class 1 Everything is limited by a single aggregate | |
2927 | bucket. | |
2928 | ||
2929 | class 2 Everything is limited by a single aggregate | |
2930 | bucket as well as an "individual" bucket chosen | |
2931 | from bits 25 through 32 of the IP address. | |
2932 | ||
2933 | class 3 Everything is limited by a single aggregate | |
2934 | bucket as well as a "network" bucket chosen | |
2935 | from bits 17 through 24 of the IP address and a | |
2936 | "individual" bucket chosen from bits 17 through | |
2937 | 32 of the IP address. | |
2938 | ||
2939 | NOTE: If an IP address is a.b.c.d | |
2940 | -> bits 25 through 32 are "d" | |
2941 | -> bits 17 through 24 are "c" | |
2942 | -> bits 17 through 32 are "c * 256 + d" | |
95e36d02 | 2943 | DOC_END |
2944 | ||
59715b38 | 2945 | NAME: delay_access |
2946 | TYPE: delay_pool_access | |
95e36d02 | 2947 | DEFAULT: none |
2948 | IFDEF: DELAY_POOLS | |
59715b38 | 2949 | LOC: Config.Delay |
95e36d02 | 2950 | DOC_START |
59715b38 | 2951 | This is used to determine which delay pool a request falls into. |
efd900cb | 2952 | The first matched delay pool is always used, i.e., if a request falls |
59715b38 | 2953 | into delay pool number one, no more delay are checked, otherwise the |
2954 | rest are checked in order of their delay pool number until they have | |
2955 | all been checked. For example, if you want some_big_clients in delay | |
2956 | pool 1 and lotsa_little_clients in delay pool 2: | |
95e36d02 | 2957 | |
6b53c392 | 2958 | Example: |
2959 | delay_access 1 allow some_big_clients | |
2960 | delay_access 1 deny all | |
2961 | delay_access 2 allow lotsa_little_clients | |
2962 | delay_access 2 deny all | |
95e36d02 | 2963 | DOC_END |
2964 | ||
59715b38 | 2965 | NAME: delay_parameters |
2966 | TYPE: delay_pool_rates | |
2967 | DEFAULT: none | |
95e36d02 | 2968 | IFDEF: DELAY_POOLS |
59715b38 | 2969 | LOC: Config.Delay |
95e36d02 | 2970 | DOC_START |
59715b38 | 2971 | This defines the parameters for a delay pool. Each delay pool has |
2972 | a number of "buckets" associated with it, as explained in the | |
2973 | description of delay_class. For a class 1 delay pool, the syntax is: | |
95e36d02 | 2974 | |
59715b38 | 2975 | delay_parameters pool aggregate |
95e36d02 | 2976 | |
59715b38 | 2977 | For a class 2 delay pool: |
95e36d02 | 2978 | |
59715b38 | 2979 | delay_parameters pool aggregate individual |
95e36d02 | 2980 | |
59715b38 | 2981 | For a class 3 delay pool: |
95e36d02 | 2982 | |
59715b38 | 2983 | delay_parameters pool aggregate network individual |
95e36d02 | 2984 | |
59715b38 | 2985 | The variables here are: |
95e36d02 | 2986 | |
59715b38 | 2987 | pool a pool number - ie, a number between 1 and the |
2988 | number specified in delay_pools as used in | |
2989 | delay_class lines. | |
95e36d02 | 2990 | |
59715b38 | 2991 | aggregate the "delay parameters" for the aggregate bucket |
2992 | (class 1, 2, 3). | |
95e36d02 | 2993 | |
59715b38 | 2994 | individual the "delay parameters" for the individual |
2995 | buckets (class 2, 3). | |
2996 | ||
2997 | network the "delay parameters" for the network buckets | |
2998 | (class 3). | |
2999 | ||
3000 | A pair of delay parameters is written restore/maximum, where restore is | |
3001 | the number of bytes (not bits - modem and network speeds are usually | |
3002 | quoted in bits) per second placed into the bucket, and maximum is the | |
3003 | maximum number of bytes which can be in the bucket at any time. | |
3004 | ||
3005 | For example, if delay pool number 1 is a class 2 delay pool as in the | |
3006 | above example, and is being used to strictly limit each host to 64kbps | |
3007 | (plus overheads), with no overall limit, the line is: | |
3008 | ||
3009 | delay_parameters 1 -1/-1 8000/8000 | |
3010 | ||
3011 | Note that the figure -1 is used to represent "unlimited". | |
3012 | ||
3013 | And, if delay pool number 2 is a class 3 delay pool as in the above | |
3014 | example, and you want to limit it to a total of 256kbps (strict limit) | |
3015 | with each 8-bit network permitted 64kbps (strict limit) and each | |
3016 | individual host permitted 4800bps with a bucket maximum size of 64kb | |
3017 | to permit a decent web page to be downloaded at a decent speed | |
3018 | (if the network is not being limited due to overuse) but slow down | |
3019 | large downloads more significantly: | |
3020 | ||
3021 | delay_parameters 2 32000/32000 8000/8000 600/64000 | |
3022 | ||
3023 | There must be one delay_parameters line for each delay pool. | |
95e36d02 | 3024 | DOC_END |
3025 | ||
59715b38 | 3026 | NAME: delay_initial_bucket_level |
3027 | COMMENT: (percent, 0-100) | |
3028 | TYPE: ushort | |
3029 | DEFAULT: 50 | |
95e36d02 | 3030 | IFDEF: DELAY_POOLS |
59715b38 | 3031 | LOC: Config.Delay.initial |
95e36d02 | 3032 | DOC_START |
59715b38 | 3033 | The initial bucket percentage is used to determine how much is put |
3034 | in each bucket when squid starts, is reconfigured, or first notices | |
3035 | a host accessing it (in class 2 and class 3, individual hosts and | |
3036 | networks only have buckets associated with them once they have been | |
3037 | "seen" by squid). | |
95e36d02 | 3038 | DOC_END |
6be2389e | 3039 | |
9cd6c6fb | 3040 | NAME: incoming_icp_average |
6be2389e | 3041 | TYPE: int |
3042 | DEFAULT: 6 | |
3043 | LOC: Config.comm_incoming.icp_average | |
3044 | DOC_NONE | |
3045 | ||
9cd6c6fb | 3046 | NAME: incoming_http_average |
6be2389e | 3047 | TYPE: int |
3048 | DEFAULT: 4 | |
3049 | LOC: Config.comm_incoming.http_average | |
3050 | DOC_NONE | |
3051 | ||
afc28c12 | 3052 | NAME: incoming_dns_average |
3053 | TYPE: int | |
3054 | DEFAULT: 4 | |
3055 | LOC: Config.comm_incoming.dns_average | |
3056 | DOC_NONE | |
3057 | ||
9cd6c6fb | 3058 | NAME: min_icp_poll_cnt |
6be2389e | 3059 | TYPE: int |
3060 | DEFAULT: 8 | |
3061 | LOC: Config.comm_incoming.icp_min_poll | |
3062 | DOC_NONE | |
3063 | ||
afc28c12 | 3064 | NAME: min_dns_poll_cnt |
3065 | TYPE: int | |
3066 | DEFAULT: 8 | |
3067 | LOC: Config.comm_incoming.dns_min_poll | |
3068 | DOC_NONE | |
3069 | ||
9cd6c6fb | 3070 | NAME: min_http_poll_cnt |
6be2389e | 3071 | TYPE: int |
3072 | DEFAULT: 8 | |
3073 | LOC: Config.comm_incoming.http_min_poll | |
3074 | DOC_START | |
b6a2f15e | 3075 | Heavy voodoo here. I can't even believe you are reading this. |
6be2389e | 3076 | Are you crazy? Don't even think about adjusting these unless |
3077 | you understand the algorithms in comm_select.c first! | |
3078 | DOC_END | |
2b4283e4 | 3079 | |
c5f627c2 | 3080 | NAME: max_open_disk_fds |
3081 | TYPE: int | |
3082 | LOC: Config.max_open_disk_fds | |
3083 | DEFAULT: 0 | |
6b53c392 | 3084 | DOC_START |
3085 | To avoid having disk as the I/O bottleneck Squid can optionally | |
3086 | bypass the on-disk cache if more than this amount of disk file | |
3087 | descriptors are open. | |
3088 | ||
3089 | A value of 0 indicates no limit. | |
3090 | DOC_END | |
c5f627c2 | 3091 | |
b540e168 | 3092 | NAME: offline_mode |
3093 | TYPE: onoff | |
3094 | LOC: Config.onoff.offline | |
3095 | DEFAULT: off | |
3096 | DOC_START | |
3097 | Enable this option and Squid will never try to validate cached | |
3098 | objects. | |
3099 | DOC_END | |
3100 | ||
d548ee64 | 3101 | NAME: uri_whitespace |
3102 | TYPE: uri_whitespace | |
3103 | LOC: Config.uri_whitespace | |
7e3ce7b9 | 3104 | DEFAULT: strip |
d548ee64 | 3105 | DOC_START |
3106 | What to do with requests that have whitespace characters in the | |
3107 | URI. Options: | |
3108 | ||
7e3ce7b9 | 3109 | strip: The whitespace characters are stripped out of the URL. |
3110 | This is the behavior recommended by RFC2616. | |
d548ee64 | 3111 | deny: The request is denied. The user receives an "Invalid |
3112 | Request" message. | |
3113 | allow: The request is allowed and the URI is not changed. The | |
3114 | whitespace characters remain in the URI. Note the | |
3115 | whitespace is passed to redirector processes if they | |
3116 | are in use. | |
3117 | encode: The request is allowed and the whitespace characters are | |
3118 | encoded according to RFC1738. This could be considered | |
3119 | a violation of the HTTP/1.1 | |
3120 | RFC because proxies are not allowed to rewrite URI's. | |
3121 | chop: The request is allowed and the URI is chopped at the | |
3122 | first whitespace. This might also be considered a | |
3123 | violation. | |
d548ee64 | 3124 | DOC_END |
3125 | ||
376bb137 | 3126 | NAME: broken_posts |
3127 | TYPE: acl_access | |
3128 | DEFAULT: none | |
3129 | LOC: Config.accessList.brokenPosts | |
c68e9c6b | 3130 | DOC_START |
376bb137 | 3131 | A list of ACL elements which, if matched, causes Squid to send |
3132 | a extra CRLF pair after the body of a PUT/POST request. | |
3133 | ||
3134 | Some HTTP servers has broken implementations of PUT/POST, | |
3135 | and rely on a extra CRLF pair sent by some WWW clients. | |
3136 | ||
3137 | Quote from RFC 2068 section 4.1 on this matter: | |
3138 | ||
3139 | Note: certain buggy HTTP/1.0 client implementations generate an | |
3140 | extra CRLF's after a POST request. To restate what is explicitly | |
3141 | forbidden by the BNF, an HTTP/1.1 client must not preface or follow | |
3142 | a request with an extra CRLF. | |
3143 | ||
6b53c392 | 3144 | Example: |
3145 | acl buggy_server url_regex ^http://.... | |
3146 | broken_posts allow buggy_server | |
c68e9c6b | 3147 | DOC_END |
9b094667 | 3148 | |
e66d7923 | 3149 | NAME: mcast_miss_addr |
3150 | IFDEF: MULTICAST_MISS_STREAM | |
3151 | TYPE: address | |
3152 | LOC: Config.mcast_miss.addr | |
3153 | DEFAULT: 255.255.255.255 | |
b6a2f15e | 3154 | DOC_START |
3155 | If you enable this option, every "cache miss" URL will | |
3156 | be sent out on the specified multicast address. | |
3157 | ||
3158 | Do not enable this option unless you are are absolutely | |
3159 | certain you understand what you are doing. | |
3160 | DOC_END | |
e66d7923 | 3161 | |
7e3ce7b9 | 3162 | NAME: mcast_miss_ttl |
3163 | IFDEF: MULTICAST_MISS_TTL | |
3164 | TYPE: ushort | |
3165 | LOC: Config.mcast_miss.ttl | |
3166 | DEFAULT: 16 | |
3167 | DOC_START | |
3168 | This is the time-to-live value for packets multicasted | |
3169 | when multicasting off cache miss URLs is enabled. By | |
3170 | default this is set to 'site scope', i.e. 16. | |
3171 | DOC_END | |
3172 | ||
e66d7923 | 3173 | NAME: mcast_miss_port |
3174 | IFDEF: MULTICAST_MISS_STREAM | |
3175 | TYPE: ushort | |
3176 | LOC: Config.mcast_miss.port | |
3177 | DEFAULT: 3135 | |
b6a2f15e | 3178 | DOC_START |
efd900cb | 3179 | This is the port number to be used in conjunction with |
b6a2f15e | 3180 | 'mcast_miss_addr'. |
3181 | DOC_END | |
e66d7923 | 3182 | |
3183 | NAME: mcast_miss_encode_key | |
3184 | IFDEF: MULTICAST_MISS_STREAM | |
3185 | TYPE: string | |
3186 | LOC: Config.mcast_miss.encode_key | |
3187 | DEFAULT: XXXXXXXXXXXXXXXX | |
b6a2f15e | 3188 | DOC_START |
3189 | The URLs that are sent in the multicast miss stream are | |
3190 | encrypted. This is the encryption key. | |
3191 | DOC_END | |
e66d7923 | 3192 | |
168dfda9 | 3193 | NAME: nonhierarchical_direct |
3194 | TYPE: onoff | |
3195 | LOC: Config.onoff.nonhierarchical_direct | |
3196 | DEFAULT: on | |
3197 | DOC_START | |
3198 | By default, Squid will send any non-hierarchical requests | |
3199 | (matching hierarchy_stoplist or not cachable request type) direct | |
3200 | to origin servers. | |
3201 | ||
3202 | If you set this to off, then Squid will prefer to send these | |
3203 | requests to parents. | |
3204 | ||
3205 | Note that in most configurations, by turning this off you will only | |
3206 | add latency to these request without any improvement in global hit | |
3207 | ratio. | |
3208 | ||
3209 | If you are inside an firewall then see never_direct instead of | |
3210 | this directive. | |
168dfda9 | 3211 | DOC_END |
3212 | ||
9b094667 | 3213 | NAME: prefer_direct |
3214 | TYPE: onoff | |
3215 | LOC: Config.onoff.prefer_direct | |
168dfda9 | 3216 | DEFAULT: off |
9b094667 | 3217 | DOC_START |
168dfda9 | 3218 | Normally Squid tries to use parents for most requests. If you by some |
3219 | reason like it to first try going direct and only use a parent if | |
3220 | going direct fails then set this to off. | |
3221 | ||
3222 | By combining nonhierarchical_direct off and prefer_direct on you | |
3223 | can set up Squid to use a parent as a backup path if going direct | |
3224 | fails. | |
9b094667 | 3225 | DOC_END |
4d62b0af | 3226 | |
bcbc11b0 | 3227 | NAME: strip_query_terms |
3228 | TYPE: onoff | |
3229 | LOC: Config.onoff.strip_query_terms | |
3230 | DEFAULT: on | |
3231 | DOC_START | |
3232 | By default, Squid strips query terms from requested URLs before | |
3233 | logging. This protects your user's privacy. | |
bcbc11b0 | 3234 | DOC_END |
3235 | ||
b6a2f15e | 3236 | NAME: coredump_dir |
3237 | TYPE: string | |
3238 | LOC: Config.coredump_dir | |
3239 | DEFAULT: none | |
5ff76111 | 3240 | DEFAULT_IF_NONE: none |
b6a2f15e | 3241 | DOC_START |
5ff76111 | 3242 | By default Squid leaves core files in the directory from where |
3243 | it was started. If you set 'coredump_dir' to a directory | |
b6a2f15e | 3244 | that exists, Squid will chdir() to that directory at startup |
3245 | and coredump files will be left there. | |
5ff76111 | 3246 | |
3247 | NOCOMMENT_START | |
3248 | # Leave coredumps in the first cache dir | |
3249 | coredump_dir @DEFAULT_SWAP_DIR@ | |
3250 | NOCOMMENT_END | |
b6a2f15e | 3251 | DOC_END |
3252 | ||
07476a7f | 3253 | NAME: redirector_bypass |
3254 | TYPE: onoff | |
3255 | LOC: Config.onoff.redirector_bypass | |
3256 | DEFAULT: off | |
3257 | DOC_START | |
3258 | When this is 'on', a request will not go through the | |
3259 | redirector if all redirectors are busy. If this is 'off' | |
3260 | and the redirector queue grows too large, Squid will exit | |
29de1a20 | 3261 | with a FATAL error and ask you to increase the number of |
07476a7f | 3262 | redirectors. You should only enable this if the redirectors |
3263 | are not critical to your caching system. If you use | |
3264 | redirectors for access control, and you enable this option, | |
3265 | then users may have access to pages that they should not | |
3266 | be allowed to request. | |
3267 | DOC_END | |
3268 | ||
9bc73deb | 3269 | NAME: ignore_unknown_nameservers |
3270 | TYPE: onoff | |
3271 | LOC: Config.onoff.ignore_unknown_nameservers | |
3272 | DEFAULT: on | |
3273 | DOC_START | |
3274 | By default Squid checks that DNS responses are received | |
3275 | from the same IP addresses that they are sent to. If they | |
3276 | don't match, Squid ignores the response and writes a warning | |
3277 | message to cache.log. You can allow responses from unknown | |
3278 | nameservers by setting this option to 'off'. | |
9bc73deb | 3279 | DOC_END |
3280 | ||
7e3ce7b9 | 3281 | NAME: digest_generation |
3282 | IFDEF: USE_CACHE_DIGESTS | |
3283 | TYPE: onoff | |
3284 | LOC: Config.onoff.digest_generation | |
3285 | DEFAULT: on | |
3286 | DOC_START | |
3287 | This controls whether the server will generate a Cache Digest | |
3288 | of its contents. By default, Cache Digest generation is | |
3289 | enabled if Squid is compiled with USE_CACHE_DIGESTS defined. | |
7e3ce7b9 | 3290 | DOC_END |
3291 | ||
3292 | NAME: digest_bits_per_entry | |
3293 | IFDEF: USE_CACHE_DIGESTS | |
3294 | TYPE: int | |
3295 | LOC: Config.digest.bits_per_entry | |
3296 | DEFAULT: 5 | |
3297 | DOC_START | |
3298 | This is the number of bits of the server's Cache Digest which | |
3299 | will be associated with the Digest entry for a given HTTP | |
3300 | Method and URL (public key) combination. The default is 5. | |
7e3ce7b9 | 3301 | DOC_END |
3302 | ||
3303 | NAME: digest_rebuild_period | |
3304 | IFDEF: USE_CACHE_DIGESTS | |
efd900cb | 3305 | COMMENT: (seconds) |
3306 | TYPE: time_t | |
7e3ce7b9 | 3307 | LOC: Config.digest.rebuild_period |
efd900cb | 3308 | DEFAULT: 1 hour |
7e3ce7b9 | 3309 | DOC_START |
3310 | This is the number of seconds between Cache Digest rebuilds. | |
7e3ce7b9 | 3311 | DOC_END |
3312 | ||
3313 | NAME: digest_rewrite_period | |
efd900cb | 3314 | COMMENT: (seconds) |
7e3ce7b9 | 3315 | IFDEF: USE_CACHE_DIGESTS |
efd900cb | 3316 | TYPE: time_t |
7e3ce7b9 | 3317 | LOC: Config.digest.rewrite_period |
efd900cb | 3318 | DEFAULT: 1 hour |
7e3ce7b9 | 3319 | DOC_START |
3320 | This is the number of seconds between Cache Digest writes to | |
6b53c392 | 3321 | disk. |
7e3ce7b9 | 3322 | DOC_END |
3323 | ||
3324 | NAME: digest_swapout_chunk_size | |
efd900cb | 3325 | COMMENT: (bytes) |
3326 | TYPE: b_size_t | |
7e3ce7b9 | 3327 | IFDEF: USE_CACHE_DIGESTS |
7e3ce7b9 | 3328 | LOC: Config.digest.swapout_chunk_size |
efd900cb | 3329 | DEFAULT: 4096 bytes |
7e3ce7b9 | 3330 | DOC_START |
3331 | This is the number of bytes of the Cache Digest to write to | |
efd900cb | 3332 | disk at a time. It defaults to 4096 bytes (4KB), the Squid |
3333 | default swap page. | |
7e3ce7b9 | 3334 | DOC_END |
3335 | ||
3336 | NAME: digest_rebuild_chunk_percentage | |
efd900cb | 3337 | COMMENT: (percent, 0-100) |
7e3ce7b9 | 3338 | IFDEF: USE_CACHE_DIGESTS |
3339 | TYPE: int | |
3340 | LOC: Config.digest.rebuild_chunk_percentage | |
3341 | DEFAULT: 10 | |
3342 | DOC_START | |
efd900cb | 3343 | This is the percentage of the Cache Digest to be scanned at a |
3344 | time. By default it is set to 10% of the Cache Digest. | |
7e3ce7b9 | 3345 | DOC_END |
3346 | ||
efd900cb | 3347 | NAME: chroot |
3348 | TYPE: string | |
3349 | LOC: Config.chroot_dir | |
3350 | DEFAULT: none | |
3351 | DOC_START | |
3352 | Use this to have Squid do a chroot() while initializing. This | |
3353 | also causes Squid to fully drop root privileges after | |
3354 | initializing. This means, for example, that if you use a HTTP | |
3355 | port less than 1024 and try to reconfigure, you will get an | |
3356 | error. | |
3357 | DOC_END | |
efd900cb | 3358 | |
3359 | NAME: client_persistent_connections | |
3360 | TYPE: onoff | |
3361 | LOC: Config.onoff.client_pconns | |
3362 | DEFAULT: on | |
3363 | DOC_NONE | |
3364 | ||
3365 | NAME: server_persistent_connections | |
3366 | TYPE: onoff | |
3367 | LOC: Config.onoff.server_pconns | |
3368 | DEFAULT: on | |
3369 | DOC_START | |
3370 | Persistent connection support for clients and servers. By | |
3371 | default, Squid uses persistent connections (when allowed) | |
3372 | with its clients and servers. You can use these options to | |
3373 | disable persistent connections with clients and/or servers. | |
efd900cb | 3374 | DOC_END |
9d24d603 | 3375 | |
56fe752e | 3376 | NAME: extension_methods |
3377 | TYPE: wordlist | |
3378 | LOC: Config.ext_methods | |
3379 | DEFAULT: none | |
3380 | DOC_START | |
3381 | Squid only knows about standardized HTTP request methods. | |
3382 | You can add up to 20 additional "extension" methods here. | |
3383 | DOC_END | |
3384 | ||
b8a46de0 | 3385 | NAME: high_response_time_warning |
3386 | TYPE: int | |
3387 | COMMENT: (msec) | |
3388 | LOC: Config.warnings.high_rptm | |
3389 | DEFAULT: 0 | |
3390 | DOC_START | |
3391 | If the one-minute median response time exceeds this value, | |
3392 | Squid prints a WARNING with debug level 0 to get the | |
3393 | administrators attention. The value is in milliseconds. | |
3394 | DOC_END | |
3395 | ||
3396 | NAME: high_page_fault_warning | |
3397 | TYPE: int | |
3398 | LOC: Config.warnings.high_pf | |
3399 | DEFAULT: 0 | |
3400 | DOC_START | |
3401 | If the one-minute average page fault rate exceeds this | |
3402 | value, Squid prints a WARNING with debug level 0 to get | |
3403 | the administrators attention. The value is in page faults | |
3404 | per second. | |
3405 | DOC_END | |
3406 | ||
3407 | NAME: high_memory_warning | |
3408 | TYPE: b_size_t | |
3409 | LOC: Config.warnings.high_memory | |
3410 | DEFAULT: 0 | |
3411 | DOC_START | |
3412 | If the memory usage (as determined by mallinfo) exceeds | |
3413 | value, Squid prints a WARNING with debug level 0 to get | |
3414 | the administrators attention. | |
3415 | DOC_END | |
3416 | ||
65a53c8e | 3417 | NAME: store_dir_select_algorithm |
3418 | TYPE: string | |
3419 | LOC: Config.store_dir_select_algorithm | |
3420 | DEFAULT: least-load | |
3421 | DOC_START | |
3422 | Set this to 'round-robin' as an alternative. | |
3423 | DOC_END | |
3424 | ||
225644d7 | 3425 | NAME: forward_log |
3426 | IFDEF: WIP_FWD_LOG | |
3427 | TYPE: string | |
3428 | DEFAULT: none | |
3429 | LOC: Config.Log.forward | |
3430 | DOC_START | |
3431 | Logs the server-side requests. | |
3432 | ||
3433 | This is currently work in progress. | |
3434 | DOC_END | |
3435 | ||
7613d09c | 3436 | NAME: ie_refresh |
3437 | COMMENT: on|off | |
3438 | TYPE: onoff | |
3439 | LOC: Config.onoff.ie_refresh | |
3440 | DEFAULT: off | |
3441 | DOC_START | |
3442 | Microsoft Internet Explorer up until version 5.5 Service | |
3443 | Pack 1 has an issue with transparent proxies, wherein it | |
3444 | is impossible to force a refresh. Turning this on provides | |
3445 | a partial fix to the problem, by causing all IMS-REFRESH | |
3446 | requests from older IE versions to check the origin server | |
3447 | for fresh content. This reduces hit ratio by some amount | |
3448 | (~10% in my experience), but allows users to actually get | |
3449 | fresh content when they want it. Note that because Squid | |
3450 | cannot tell if the user is using 5.5 or 5.5SP1, the behavior | |
3451 | of 5.5 is unchanged from old versions of Squid (i.e. a | |
3452 | forced refresh is impossible). Newer versions of IE will, | |
3453 | hopefully, continue to have the new behavior and will be | |
3454 | handled based on that assumption. This option defaults to | |
3455 | the old Squid behavior, which is better for hit ratios but | |
3456 | worse for clients using IE, if they need to be able to | |
3457 | force fresh content. | |
3458 | DOC_END | |
3459 | ||
2b4283e4 | 3460 | EOF |
7e3ce7b9 | 3461 |