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