File: varnishd.1

package info (click to toggle)
varnish 6.5.1-1%2Bdeb11u3
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 19,720 kB
  • sloc: ansic: 95,295; javascript: 9,411; sh: 4,673; python: 2,157; makefile: 1,353; awk: 114; ruby: 34
file content (2577 lines) | stat: -rw-r--r-- 62,631 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
2165
2166
2167
2168
2169
2170
2171
2172
2173
2174
2175
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
2200
2201
2202
2203
2204
2205
2206
2207
2208
2209
2210
2211
2212
2213
2214
2215
2216
2217
2218
2219
2220
2221
2222
2223
2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
2275
2276
2277
2278
2279
2280
2281
2282
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
2323
2324
2325
2326
2327
2328
2329
2330
2331
2332
2333
2334
2335
2336
2337
2338
2339
2340
2341
2342
2343
2344
2345
2346
2347
2348
2349
2350
2351
2352
2353
2354
2355
2356
2357
2358
2359
2360
2361
2362
2363
2364
2365
2366
2367
2368
2369
2370
2371
2372
2373
2374
2375
2376
2377
2378
2379
2380
2381
2382
2383
2384
2385
2386
2387
2388
2389
2390
2391
2392
2393
2394
2395
2396
2397
2398
2399
2400
2401
2402
2403
2404
2405
2406
2407
2408
2409
2410
2411
2412
2413
2414
2415
2416
2417
2418
2419
2420
2421
2422
2423
2424
2425
2426
2427
2428
2429
2430
2431
2432
2433
2434
2435
2436
2437
2438
2439
2440
2441
2442
2443
2444
2445
2446
2447
2448
2449
2450
2451
2452
2453
2454
2455
2456
2457
2458
2459
2460
2461
2462
2463
2464
2465
2466
2467
2468
2469
2470
2471
2472
2473
2474
2475
2476
2477
2478
2479
2480
2481
2482
2483
2484
2485
2486
2487
2488
2489
2490
2491
2492
2493
2494
2495
2496
2497
2498
2499
2500
2501
2502
2503
2504
2505
2506
2507
2508
2509
2510
2511
2512
2513
2514
2515
2516
2517
2518
2519
2520
2521
2522
2523
2524
2525
2526
2527
2528
2529
2530
2531
2532
2533
2534
2535
2536
2537
2538
2539
2540
2541
2542
2543
2544
2545
2546
2547
2548
2549
2550
2551
2552
2553
2554
2555
2556
2557
2558
2559
2560
2561
2562
2563
2564
2565
2566
2567
2568
2569
2570
2571
2572
2573
2574
2575
2576
2577
.\" Man page generated from reStructuredText.
.
.TH VARNISHD 1 "" "" ""
.SH NAME
varnishd \- HTTP accelerator daemon
.
.nr rst2man-indent-level 0
.
.de1 rstReportMargin
\\$1 \\n[an-margin]
level \\n[rst2man-indent-level]
level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
-
\\n[rst2man-indent0]
\\n[rst2man-indent1]
\\n[rst2man-indent2]
..
.de1 INDENT
.\" .rstReportMargin pre:
. RS \\$1
. nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin]
. nr rst2man-indent-level +1
.\" .rstReportMargin post:
..
.de UNINDENT
. RE
.\" indent \\n[an-margin]
.\" old: \\n[rst2man-indent\\n[rst2man-indent-level]]
.nr rst2man-indent-level -1
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.SH SYNOPSIS
.sp
varnishd [\-a [name=][address][:port][,PROTO][,user=<user>][,group=<group>][,mode=<mode>]] [\-b [host[:port]|path]] [\-C] [\-d] [\-F] [\-f config] [\-h type[,options]] [\-I clifile] [\-i identity] [\-j jail[,jailoptions]] [\-l vsl] [\-M address:port] [\-n name] [\-P file] [\-p param=value] [\-r param[,param...]] [\-S secret\-file] [\-s [name=]kind[,options]] [\-T address[:port]] [\-t TTL] [\-V] [\-W waiter]
.sp
varnishd [\-x parameter|vsl|cli|builtin|optstring]
.sp
varnishd [\-?]
.SH DESCRIPTION
.sp
The \fIvarnishd\fP daemon accepts HTTP requests from clients, passes them on
to a backend server and caches the returned documents to better
satisfy future requests for the same document.
.SH OPTIONS
.SS Basic options
.sp
\-a <[name=][address][:port][,PROTO][,user=<user>][,group=<group>][,mode=<mode>]>
.INDENT 0.0
.INDENT 3.5
Listen for client requests on the specified address and port. The
address can be a host name ("localhost"), an IPv4 dotted\-quad
("127.0.0.1"), an IPv6 address enclosed in square brackets
("[::1]"), or a path beginning with a \(aq/\(aq for a Unix domain socket
("/path/to/listen.sock"). If address is not specified, \fIvarnishd\fP
will listen on all available IPv4 and IPv6 interfaces. If port is
not specified, port 80 (http) is used. At least one of address or
port is required.
.sp
If a Unix domain socket is specified as the listen address, then the
user, group and mode sub\-arguments may be used to specify the
permissions of the socket file \-\- use names for user and group, and
a 3\-digit octal value for mode. These sub\-arguments are not
permitted if an IP address is specified. When Unix domain socket
listeners are in use, all VCL configurations must have version >=
4.1.
.sp
Name is referenced in logs. If name is not specified, "a0", "a1",
etc. is used. An additional protocol type can be set for the
listening socket with PROTO. Valid protocol types are: HTTP
(default), and PROXY.
.sp
Multiple listening addresses can be specified by using different
\-a arguments.
.UNINDENT
.UNINDENT
.INDENT 0.0
.TP
.BI \-b \ <[host[:port]|path]>
Use the specified host as backend server. If port is not specified,
the default is 8080.
.sp
If the value of \fB\-b\fP begins with \fB/\fP, it is interpreted as the
absolute path of a Unix domain socket to which Varnish connects. In
that case, the value of \fB\-b\fP must satisfy the conditions required
for the \fB\&.path\fP field of a backend declaration, see \fIvcl(7)\fP\&.
Backends with Unix socket addresses may only be used with VCL
versions >= 4.1.
.sp
\-b can be used only once, and not together with f.
.TP
.BI \-f \ config
Use the specified VCL configuration file instead of the builtin
default.  See \fIvcl(7)\fP for details on VCL syntax.
.sp
If a single \-f option is used, then the VCL instance loaded from the
file is named "boot" and immediately becomes active. If more than
one \-f option is used, the VCL instances are named "boot0", "boot1"
and so forth, in the order corresponding to the \-f arguments, and
the last one is named "boot", which becomes active.
.sp
Either \-b or one or more \-f options must be specified, but not both,
and they cannot both be left out, unless \-d is used to start
\fIvarnishd\fP in debugging mode. If the empty string is specified as
the sole \-f option, then \fIvarnishd\fP starts without starting the
worker process, and the management process will accept CLI commands.
You can also combine an empty \-f option with an initialization
script (\-I option) and the child process will be started if there
is an active VCL at the end of the initialization.
.sp
When used with a relative file name, config is searched in the
\fBvcl_path\fP\&. It is possible to set this path prior to using \fB\-f\fP
options with a \fB\-p\fP option. During startup, \fIvarnishd\fP doesn\(aqt
complain about unsafe VCL paths: unlike the \fIvarnish\-cli(7)\fP that
could later be accessed remotely, starting \fIvarnishd\fP requires
local privileges.
.UNINDENT
.INDENT 0.0
.TP
.BI \-n \ name
Specify the name for this instance.  This name is used to construct
the name of the directory in which \fIvarnishd\fP keeps temporary files
and persistent state. If the specified name begins with a forward slash,
it is interpreted as the absolute path to the directory.
.UNINDENT
.SS Documentation options
.sp
For these options, \fIvarnishd\fP prints information to standard output
and exits. When a \-x option is used, it must be the only option (it
outputs documentation in reStructuredText, aka RST).
.sp
\-?
.INDENT 0.0
.INDENT 3.5
Print the usage message.
.UNINDENT
.UNINDENT
.INDENT 0.0
.TP
.BI \-x \ parameter
Print documentation of the runtime parameters (\-p options), see
\fI\%List of Parameters\fP\&.
.TP
.BI \-x \ vsl
Print documentation of the tags used in the Varnish shared memory
log, see \fIvsl(7)\fP\&.
.TP
.BI \-x \ cli
Print documentation of the command line interface, see
\fIvarnish\-cli(7)\fP\&.
.TP
.BI \-x \ builtin
Print the contents of the default VCL program \fBbuiltin.vcl\fP\&.
.TP
.BI \-x \ optstring
Print the optstring parameter to \fBgetopt(3)\fP to help writing
wrapper scripts.
.UNINDENT
.SS Operations options
.INDENT 0.0
.TP
.B \-F
Do not fork, run in the foreground. Only one of \-F or \-d can be
specified, and \-F cannot be used together with \-C.
.TP
.BI \-T \ <address[:port]>
Offer a management interface on the specified address and port. See
\fIvarnish\-cli(7)\fP for documentation of the management commands.
To disable the management interface use \fBnone\fP\&.
.TP
.BI \-M \ <address:port>
Connect to this port and offer the command line interface.  Think of
it as a reverse shell. When running with \-M and there is no backend
defined the child process (the cache) will not start initially.
.TP
.BI \-P \ file
Write the PID of the process to the specified file.
.TP
.BI \-i \ identity
Specify the identity of the Varnish server. This can be accessed
using \fBserver.identity\fP from VCL and with VSM_Name() from
utilities.  If not specified the output of gethostname(3) is used.
.TP
.BI \-I \ clifile
Execute the management commands in the file given as \fBclifile\fP
before the the worker process starts, see \fI\%CLI Command File\fP\&.
.UNINDENT
.SS Tuning options
.INDENT 0.0
.TP
.BI \-t \ TTL
Specifies the default time to live (TTL) for cached objects. This is
a shortcut for specifying the \fIdefault_ttl\fP run\-time parameter.
.TP
.BI \-p \ <param=value>
Set the parameter specified by param to the specified value, see
\fI\%List of Parameters\fP for details. This option can be used multiple
times to specify multiple parameters.
.TP
.BI \-s \ <[name=]type[,options]>
Use the specified storage backend. See \fI\%Storage Backend\fP section.
.sp
This option can be used multiple times to specify multiple storage
files. Name is referenced in logs, VCL, statistics, etc. If name
is not specified, "s0", "s1" and so forth is used.
.TP
.BI \-l \ <vsl>
Specifies size of the space for the VSL records, shorthand for
\fB\-p vsl_space=<vsl>\fP\&. Scaling suffixes like \(aqK\(aq and \(aqM\(aq can be
used up to (G)igabytes. See \fI\%vsl_space\fP for more information.
.UNINDENT
.SS Security options
.INDENT 0.0
.TP
.BI \-r \ <param[,param...]>
Make the listed parameters read only. This gives the system
administrator a way to limit what the Varnish CLI can do.  Consider
making parameters such as \fIcc_command\fP, \fIvcc_allow_inline_c\fP and
\fIvmod_path\fP read only as these can potentially be used to escalate
privileges from the CLI.
.TP
.BI \-S \ secret\-file
Path to a file containing a secret used for authorizing access to
the management port. To disable authentication use \fBnone\fP\&.
.sp
If this argument is not provided, a secret drawn from the system
PRNG will be written to a file called \fB_.secret\fP in the working
directory (see \fI\%opt_n\fP) with default ownership and permissions of
the user having started varnish.
.sp
Thus, users wishing to delegate control over varnish will probably
want to create a custom secret file with appropriate permissions
(ie. readable by a unix group to delegate control to).
.TP
.BI \-j \ <jail[,jailoptions]>
Specify the jailing mechanism to use. See \fI\%Jail\fP section.
.UNINDENT
.SS Advanced, development and debugging options
.INDENT 0.0
.TP
.B \-d
Enables debugging mode: The parent process runs in the foreground
with a CLI connection on stdin/stdout, and the child process must be
started explicitly with a CLI command. Terminating the parent
process will also terminate the child.
.sp
Only one of \-d or \-F can be specified, and \-d cannot be used together
with \-C.
.TP
.B \-C
Print VCL code compiled to C language and exit. Specify the VCL file
to compile with the \-f option. Either \-f or \-b must be used with \-C,
and \-C cannot be used with \-F or \-d.
.TP
.B \-V
Display the version number and exit. This must be the only option.
.TP
.BI \-h \ <type[,options]>
Specifies the hash algorithm. See \fI\%Hash Algorithm\fP section for a list
of supported algorithms.
.TP
.BI \-W \ waiter
Specifies the waiter type to use.
.UNINDENT
.SS Hash Algorithm
.sp
The following hash algorithms are available:
.INDENT 0.0
.TP
.BI \-h \ critbit
self\-scaling tree structure. The default hash algorithm in Varnish
Cache 2.1 and onwards. In comparison to a more traditional B tree
the critbit tree is almost completely lockless. Do not change this
unless you are certain what you\(aqre doing.
.TP
.BI \-h \ simple_list
A simple doubly\-linked list.  Not recommended for production use.
.TP
.BI \-h \ <classic[,buckets]>
A standard hash table. The hash key is the CRC32 of the object\(aqs URL
modulo the size of the hash table.  Each table entry points to a
list of elements which share the same hash key. The buckets
parameter specifies the number of entries in the hash table.  The
default is 16383.
.UNINDENT
.SS Storage Backend
.sp
The argument format to define storage backends is:
.INDENT 0.0
.TP
.BI \-s \ <[name]=kind[,options]>
If \fIname\fP is omitted, Varnish will name storages \fBs\fP\fIN\fP,
starting with \fBs0\fP and incrementing \fIN\fP for every new storage.
.sp
For \fIkind\fP and \fIoptions\fP see details below.
.UNINDENT
.sp
Storages can be used in vcl as \fBstorage.\fP\fIname\fP, so, for
example if \fBmyStorage\fP was defined by \fB\-s myStorage=malloc,5G\fP, it
could be used in VCL like so:
.INDENT 0.0
.INDENT 3.5
.sp
.nf
.ft C
set beresp.storage = storage.myStorage;
.ft P
.fi
.UNINDENT
.UNINDENT
.sp
A special \fIname\fP is \fBTransient\fP which is the default storage for
uncacheable objects as resulting from a pass, hit\-for\-miss or
hit\-for\-pass.
.sp
If no \fB\-s\fP options are given, the default is:
.INDENT 0.0
.INDENT 3.5
.sp
.nf
.ft C
\-s malloc=100m
.ft P
.fi
.UNINDENT
.UNINDENT
.sp
If no \fBTransient\fP storage is defined, the default is an unbound
\fBmalloc\fP storage as if defined as:
.INDENT 0.0
.INDENT 3.5
.sp
.nf
.ft C
\-s Transient=malloc
.ft P
.fi
.UNINDENT
.UNINDENT
.sp
The following storage types and options are available:
.INDENT 0.0
.TP
.BI \-s \ <default[,size]>
The default storage type resolves to umem where available and malloc
otherwise.
.TP
.BI \-s \ <malloc[,size]>
malloc is a memory based backend.
.TP
.BI \-s \ <umem[,size]>
umem is a storage backend which is more efficient than malloc on
platforms where it is available.
.sp
See the section on umem in chapter \fIStorage backends\fP of \fIThe
Varnish Users Guide\fP for details.
.TP
.BI \-s \ <file,path[,size[,granularity[,advice]]]>
The file backend stores data in a file on disk. The file will be
accessed using mmap. Note that this storage provide no cache persistence.
.sp
The path is mandatory. If path points to a directory, a temporary
file will be created in that directory and immediately unlinked. If
path points to a non\-existing file, the file will be created.
.sp
If size is omitted, and path points to an existing file with a size
greater than zero, the size of that file will be used. If not, an
error is reported.
.sp
Granularity sets the allocation block size. Defaults to the system
page size or the filesystem block size, whichever is larger.
.sp
Advice tells the kernel how \fIvarnishd\fP expects to use this mapped
region so that the kernel can choose the appropriate read\-ahead
and caching techniques. Possible values are \fBnormal\fP, \fBrandom\fP
and \fBsequential\fP, corresponding to MADV_NORMAL, MADV_RANDOM and
MADV_SEQUENTIAL madvise() advice argument, respectively. Defaults to
\fBrandom\fP\&.
.TP
.BI \-s \ <persistent,path,size>
Persistent storage. Varnish will store objects in a file in a manner
that will secure the survival of \fImost\fP of the objects in the event
of a planned or unplanned shutdown of Varnish. The persistent
storage backend has multiple issues with it and will likely be
removed from a future version of Varnish.
.UNINDENT
.SS Jail
.sp
Varnish jails are a generalization over various platform specific
methods to reduce the privileges of varnish processes. They may have
specific options. Available jails are:
.INDENT 0.0
.TP
.BI \-j \ <solaris[,worker=\(gaprivspec\(ga]>
Reduce \fIprivileges(5)\fP for \fIvarnishd\fP and sub\-process to the
minimally required set. Only available on platforms which have the
\fIsetppriv(2)\fP call.
.sp
The optional \fIworker\fP argument can be used to pass a
privilege\-specification (see \fIppriv(1)\fP) by which to extend the
effective set of the varnish worker process. While extended
privileges may be required by custom vmods, it is always the more
secure to \fInot\fP use the \fIworker\fP option.
.sp
Example to grant basic privileges to the worker process:
.INDENT 7.0
.INDENT 3.5
.sp
.nf
.ft C
\-j solaris,worker=basic
.ft P
.fi
.UNINDENT
.UNINDENT
.TP
.BI \-j \ <unix[,user=\(gauser\(ga][,ccgroup=\(gagroup\(ga][,workuser=\(gauser\(ga]>
Default on all other platforms when \fIvarnishd\fP is started with an
effective uid of 0 ("as root").
.sp
With the \fBunix\fP jail mechanism activated, varnish will switch to
an alternative user for subprocesses and change the effective uid of
the master process whenever possible.
.sp
The optional \fIuser\fP argument specifies which alternative user to
use. It defaults to \fBvarnish\fP\&.
.sp
The optional \fIccgroup\fP argument specifies a group to add to varnish
subprocesses requiring access to a c\-compiler. There is no default.
.sp
The optional \fIworkuser\fP argument specifies an alternative user to use
for the worker process. It defaults to \fBvcache\fP\&.
.TP
.BI \-j \ none
last resort jail choice: With jail mechanism \fBnone\fP, varnish will
run all processes with the privileges it was started with.
.UNINDENT
.SS Management Interface
.sp
If the \-T option was specified, \fIvarnishd\fP will offer a command\-line
management interface on the specified address and port.  The
recommended way of connecting to the command\-line management interface
is through \fIvarnishadm(1)\fP\&.
.sp
The commands available are documented in \fIvarnish\-cli(7)\fP\&.
.SS CLI Command File
.sp
The \-I option makes it possible to run arbitrary management commands
when \fIvarnishd\fP is launched, before the worker process is started. In
particular, this is the way to load configurations, apply labels to
them, and make a VCL instance active that uses those labels on
startup:
.INDENT 0.0
.INDENT 3.5
.sp
.nf
.ft C
vcl.load panic /etc/varnish_panic.vcl
vcl.load siteA0 /etc/varnish_siteA.vcl
vcl.load siteB0 /etc/varnish_siteB.vcl
vcl.load siteC0 /etc/varnish_siteC.vcl
vcl.label siteA siteA0
vcl.label siteB siteB0
vcl.label siteC siteC0
vcl.load main /etc/varnish_main.vcl
vcl.use main
.ft P
.fi
.UNINDENT
.UNINDENT
.sp
Every line in the file, including the last line, must be terminated by
a newline or carriage return.
.sp
If a command in the file is prefixed with \(aq\-\(aq, failure will not abort
the startup.
.SH RUN TIME PARAMETERS
.SS Run Time Parameter Flags
.sp
Runtime parameters are marked with shorthand flags to avoid repeating
the same text over and over in the table below. The meaning of the
flags are:
.INDENT 0.0
.IP \(bu 2
\fIexperimental\fP
.sp
We have no solid information about good/bad/optimal values for this
parameter. Feedback with experience and observations are most
welcome.
.IP \(bu 2
\fIdelayed\fP
.sp
This parameter can be changed on the fly, but will not take effect
immediately.
.IP \(bu 2
\fIrestart\fP
.sp
The worker process must be stopped and restarted, before this
parameter takes effect.
.IP \(bu 2
\fIreload\fP
.sp
The VCL programs must be reloaded for this parameter to take effect.
.IP \(bu 2
\fIwizard\fP
.sp
Do not touch unless you \fIreally\fP know what you\(aqre doing.
.IP \(bu 2
\fIonly_root\fP
.sp
Only works if \fIvarnishd\fP is running as root.
.UNINDENT
.SS Default Value Exceptions on 32 bit Systems
.sp
Be aware that on 32 bit systems, certain default or maximum values are
reduced relative to the values listed below, in order to conserve VM
space:
.INDENT 0.0
.IP \(bu 2
workspace_client: 24k
.IP \(bu 2
workspace_backend: 20k
.IP \(bu 2
http_resp_size: 8k
.IP \(bu 2
http_req_size: 12k
.IP \(bu 2
gzip_buffer: 4k
.IP \(bu 2
vsl_space: 1G (maximum)
.IP \(bu 2
thread_pool_stack: 52k
.UNINDENT
.SS List of Parameters
.sp
This text is produced from the same text you will find in the CLI if
you use the param.show command:
.\" The following is the autogenerated output from varnishd -x parameter
.
.SS accept_filter
.sp
NB: This parameter depends on a feature which is not available on all platforms.
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bool
.IP \(bu 2
Default: on (if your platform supports accept filters)
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Enable kernel accept\-filters. This may require a kernel module to be loaded to have an effect when enabled.
.sp
Enabling accept_filter may prevent some requests to reach Varnish in the first place. Malformed requests may go unnoticed and not increase the client_req_400 counter. GET or HEAD requests with a body may be blocked altogether.
.SS acceptor_sleep_decay
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Default: 0.9
.IP \(bu 2
Minimum: 0
.IP \(bu 2
Maximum: 1
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
If we run out of resources, such as file descriptors or worker threads, the acceptor will sleep between accepts.
This parameter (multiplicatively) reduce the sleep duration for each successful accept. (ie: 0.9 = reduce by 10%)
.SS acceptor_sleep_incr
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 0.000
.IP \(bu 2
Minimum: 0.000
.IP \(bu 2
Maximum: 1.000
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
If we run out of resources, such as file descriptors or worker threads, the acceptor will sleep between accepts.
This parameter control how much longer we sleep, each time we fail to accept a new connection.
.SS acceptor_sleep_max
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 0.050
.IP \(bu 2
Minimum: 0.000
.IP \(bu 2
Maximum: 10.000
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
If we run out of resources, such as file descriptors or worker threads, the acceptor will sleep between accepts.
This parameter limits how long it can sleep between attempts to accept new connections.
.SS auto_restart
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bool
.IP \(bu 2
Default: on
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Automatically restart the child/worker process if it dies.
.SS backend_idle_timeout
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 60.000
.IP \(bu 2
Minimum: 1.000
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Timeout before we close unused backend connections.
.SS backend_local_error_holddown
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 10.000
.IP \(bu 2
Minimum: 0.000
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
When connecting to backends, certain error codes (EADDRNOTAVAIL, EACCESS, EPERM) signal a local resource shortage or configuration issue for which retrying connection attempts may worsen the situation due to the complexity of the operations involved in the kernel.
This parameter prevents repeated connection attempts for the configured duration.
.SS backend_remote_error_holddown
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 0.250
.IP \(bu 2
Minimum: 0.000
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
When connecting to backends, certain error codes (ECONNREFUSED, ENETUNREACH) signal fundamental connection issues such as the backend not accepting connections or routing problems for which repeated connection attempts are considered useless
This parameter prevents repeated connection attempts for the configured duration.
.SS ban_cutoff
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bans
.IP \(bu 2
Default: 0
.IP \(bu 2
Minimum: 0
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Expurge long tail content from the cache to keep the number of bans below this value. 0 disables.
.sp
When this parameter is set to a non\-zero value, the ban lurker continues to work the ban list as usual top to bottom, but when it reaches the ban_cutoff\-th ban, it treats all objects as if they matched a ban and expurges them from cache. As actively used objects get tested against the ban list at request time and thus are likely to be associated with bans near the top of the ban list, with ban_cutoff, least recently accessed objects (the "long tail") are removed.
.sp
This parameter is a safety net to avoid bad response times due to bans being tested at lookup time. Setting a cutoff trades response time for cache efficiency. The recommended value is proportional to rate(bans_lurker_tests_tested) / n_objects while the ban lurker is working, which is the number of bans the system can sustain. The additional latency due to request ban testing is in the order of ban_cutoff / rate(bans_lurker_tests_tested). For example, for rate(bans_lurker_tests_tested) = 2M/s and a tolerable latency of 100ms, a good value for ban_cutoff may be 200K.
.SS ban_dups
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bool
.IP \(bu 2
Default: on
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Eliminate older identical bans when a new ban is added.  This saves CPU cycles by not comparing objects to identical bans.
This is a waste of time if you have many bans which are never identical.
.SS ban_lurker_age
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 60.000
.IP \(bu 2
Minimum: 0.000
.UNINDENT
.UNINDENT
.UNINDENT
.sp
The ban lurker will ignore bans until they are this old.  When a ban is added, the active traffic will be tested against it as part of object lookup.  Because many applications issue bans in bursts, this parameter holds the ban\-lurker off until the rush is over.
This should be set to the approximate time which a ban\-burst takes.
.SS ban_lurker_batch
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Default: 1000
.IP \(bu 2
Minimum: 1
.UNINDENT
.UNINDENT
.UNINDENT
.sp
The ban lurker sleeps ${ban_lurker_sleep} after examining this many objects.  Use this to pace the ban\-lurker if it eats too many resources.
.SS ban_lurker_holdoff
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 0.010
.IP \(bu 2
Minimum: 0.000
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
How long the ban lurker sleeps when giving way to lookup due to lock contention.
.SS ban_lurker_sleep
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 0.010
.IP \(bu 2
Minimum: 0.000
.UNINDENT
.UNINDENT
.UNINDENT
.sp
How long the ban lurker sleeps after examining ${ban_lurker_batch} objects.  Use this to pace the ban\-lurker if it eats too many resources.
A value of zero will disable the ban lurker entirely.
.SS between_bytes_timeout
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 60.000
.IP \(bu 2
Minimum: 0.000
.UNINDENT
.UNINDENT
.UNINDENT
.sp
We only wait for this many seconds between bytes received from the backend before giving up the fetch.
VCL values, per backend or per backend request take precedence.
This parameter does not apply to pipe\(aqed requests.
.SS cc_command
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Default: defined when Varnish is built
.IP \(bu 2
Flags: must_reload
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Command used for compiling the C source code to a dlopen(3) loadable object.  Any occurrence of %s in the string will be replaced with the source file name, and %o will be replaced with the output file name.
.SS cli_limit
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 48k
.IP \(bu 2
Minimum: 128b
.IP \(bu 2
Maximum: 99999999b
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Maximum size of CLI response.  If the response exceeds this limit, the response code will be 201 instead of 200 and the last line will indicate the truncation.
.SS cli_timeout
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 60.000
.IP \(bu 2
Minimum: 0.000
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Timeout for the childs replies to CLI requests from the mgt_param.
.SS clock_skew
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 10
.IP \(bu 2
Minimum: 0
.UNINDENT
.UNINDENT
.UNINDENT
.sp
How much clockskew we are willing to accept between the backend and our own clock.
.SS clock_step
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 1.000
.IP \(bu 2
Minimum: 0.000
.UNINDENT
.UNINDENT
.UNINDENT
.sp
How much observed clock step we are willing to accept before we panic.
.SS connect_timeout
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 3.500
.IP \(bu 2
Minimum: 0.000
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Default connection timeout for backend connections. We only try to connect to the backend for this many seconds before giving up. VCL can override this default value for each backend and backend request.
.SS critbit_cooloff
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 180.000
.IP \(bu 2
Minimum: 60.000
.IP \(bu 2
Maximum: 254.000
.IP \(bu 2
Flags: wizard
.UNINDENT
.UNINDENT
.UNINDENT
.sp
How long the critbit hasher keeps deleted objheads on the cooloff list.
.SS debug
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Default: none
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Enable/Disable various kinds of debugging.
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.TP
.B \fInone\fP
Disable all debugging
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Use +/\- prefix to set/reset individual bits:
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.TP
.B \fIreq_state\fP
VSL Request state engine
.TP
.B \fIworkspace\fP
VSL Workspace operations
.TP
.B \fIwaitinglist\fP
VSL Waitinglist events
.TP
.B \fIsyncvsl\fP
Make VSL synchronous
.TP
.B \fIhashedge\fP
Edge cases in Hash
.TP
.B \fIvclrel\fP
Rapid VCL release
.TP
.B \fIlurker\fP
VSL Ban lurker
.TP
.B \fIesi_chop\fP
Chop ESI fetch to bits
.TP
.B \fIflush_head\fP
Flush after http1 head
.TP
.B \fIvtc_mode\fP
Varnishtest Mode
.TP
.B \fIwitness\fP
Emit WITNESS lock records
.TP
.B \fIvsm_keep\fP
Keep the VSM file on restart
.TP
.B \fIdrop_pools\fP
Drop thread pools (testing)
.TP
.B \fIslow_acceptor\fP
Slow down Acceptor
.TP
.B \fIh2_nocheck\fP
Disable various H2 checks
.TP
.B \fIvmod_so_keep\fP
Keep copied VMOD libraries
.TP
.B \fIprocessors\fP
Fetch/Deliver processors
.TP
.B \fIprotocol\fP
Protocol debugging
.TP
.B \fIvcl_keep\fP
Keep VCL C and so files
.TP
.B \fIlck\fP
Additional lock statistics
.UNINDENT
.UNINDENT
.UNINDENT
.SS default_grace
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 10.000
.IP \(bu 2
Minimum: 0.000
.IP \(bu 2
Flags: obj_sticky
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Default grace period.  We will deliver an object this long after it has expired, provided another thread is attempting to get a new copy.
.SS default_keep
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 0.000
.IP \(bu 2
Minimum: 0.000
.IP \(bu 2
Flags: obj_sticky
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Default keep period.  We will keep a useless object around this long, making it available for conditional backend fetches.  That means that the object will be removed from the cache at the end of ttl+grace+keep.
.SS default_ttl
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 120.000
.IP \(bu 2
Minimum: 0.000
.IP \(bu 2
Flags: obj_sticky
.UNINDENT
.UNINDENT
.UNINDENT
.sp
The TTL assigned to objects if neither the backend nor the VCL code assigns one.
.SS feature
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Default: none
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Enable/Disable various minor features.
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.TP
.B \fInone\fP
Disable all features.
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Use +/\- prefix to enable/disable individual feature:
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.TP
.B \fIhttp2\fP
Enable HTTP/2 protocol support.
.TP
.B \fIshort_panic\fP
Short panic message.
.TP
.B \fIno_coredump\fP
No coredumps.  Must be set before child process starts.
.TP
.B \fIhttps_scheme\fP
Extract host from full URI in the HTTP/1 request line, if the scheme is https.
.TP
.B \fIhttp_date_postel\fP
Tolerate non compliant timestamp headers like \fIDate\fP, \fILast\-Modified\fP, \fIExpires\fP etc.
.TP
.B \fIesi_ignore_https\fP
Convert \fI<esi:include src"https://...\fP to \fIhttp://...\fP
.TP
.B \fIesi_disable_xml_check\fP
Allow ESI processing on non\-XML ESI bodies
.TP
.B \fIesi_ignore_other_elements\fP
Ignore XML syntax errors in ESI bodies.
.TP
.B \fIesi_remove_bom\fP
Ignore UTF\-8 BOM in ESI bodies.
.TP
.B \fIwait_silo\fP
Wait for persistent silos to completely load before serving requests.
.UNINDENT
.UNINDENT
.UNINDENT
.SS fetch_chunksize
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 16k
.IP \(bu 2
Minimum: 4k
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
The default chunksize used by fetcher. This should be bigger than the majority of objects with short TTLs.
Internal limits in the storage_file module makes increases above 128kb a dubious idea.
.SS fetch_maxchunksize
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 0.25G
.IP \(bu 2
Minimum: 64k
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
The maximum chunksize we attempt to allocate from storage. Making this too large may cause delays and storage fragmentation.
.SS first_byte_timeout
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 60.000
.IP \(bu 2
Minimum: 0.000
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Default timeout for receiving first byte from backend. We only wait for this many seconds for the first byte before giving up.
VCL can override this default value for each backend and backend request.
This parameter does not apply to pipe\(aqed requests.
.SS gzip_buffer
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 32k
.IP \(bu 2
Minimum: 2k
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Size of malloc buffer used for gzip processing.
These buffers are used for in\-transit data, for instance gunzip\(aqed data being sent to a client.Making this space to small results in more overhead, writes to sockets etc, making it too big is probably just a waste of memory.
.SS gzip_level
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Default: 6
.IP \(bu 2
Minimum: 0
.IP \(bu 2
Maximum: 9
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Gzip compression level: 0=debug, 1=fast, 9=best
.SS gzip_memlevel
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Default: 8
.IP \(bu 2
Minimum: 1
.IP \(bu 2
Maximum: 9
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Gzip memory level 1=slow/least, 9=fast/most compression.
Memory impact is 1=1k, 2=2k, ... 9=256k.
.SS h2_header_table_size
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 4k
.IP \(bu 2
Minimum: 0b
.UNINDENT
.UNINDENT
.UNINDENT
.sp
HTTP2 header table size.
This is the size that will be used for the HPACK dynamic
decoding table.
.SS h2_initial_window_size
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 65535b
.IP \(bu 2
Minimum: 0b
.IP \(bu 2
Maximum: 2147483647b
.UNINDENT
.UNINDENT
.UNINDENT
.sp
HTTP2 initial flow control window size.
.SS h2_max_concurrent_streams
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: streams
.IP \(bu 2
Default: 100
.IP \(bu 2
Minimum: 0
.UNINDENT
.UNINDENT
.UNINDENT
.sp
HTTP2 Maximum number of concurrent streams.
This is the number of requests that can be active
at the same time for a single HTTP2 connection.
.SS h2_max_frame_size
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 16k
.IP \(bu 2
Minimum: 16k
.IP \(bu 2
Maximum: 16777215b
.UNINDENT
.UNINDENT
.UNINDENT
.sp
HTTP2 maximum per frame payload size we are willing to accept.
.SS h2_max_header_list_size
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 2147483647b
.IP \(bu 2
Minimum: 0b
.UNINDENT
.UNINDENT
.UNINDENT
.sp
HTTP2 maximum size of an uncompressed header list.
.SS h2_rx_window_increment
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 1M
.IP \(bu 2
Minimum: 1M
.IP \(bu 2
Maximum: 1G
.IP \(bu 2
Flags: wizard
.UNINDENT
.UNINDENT
.UNINDENT
.sp
HTTP2 Receive Window Increments.
How big credits we send in WINDOW_UPDATE frames
Only affects incoming request bodies (ie: POST, PUT etc.)
.SS h2_rx_window_low_water
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 10M
.IP \(bu 2
Minimum: 65535b
.IP \(bu 2
Maximum: 1G
.IP \(bu 2
Flags: wizard
.UNINDENT
.UNINDENT
.UNINDENT
.sp
HTTP2 Receive Window low water mark.
We try to keep the window at least this big
Only affects incoming request bodies (ie: POST, PUT etc.)
.SS http1_iovs
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: struct iovec (=16 bytes)
.IP \(bu 2
Default: 64
.IP \(bu 2
Minimum: 5
.IP \(bu 2
Maximum: 1024
.IP \(bu 2
Flags: wizard
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Number of io vectors to allocate for HTTP1 protocol transmission.  A HTTP1 header needs 7 + 2 per HTTP header field.  Allocated from workspace_thread.
.SS http_gzip_support
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bool
.IP \(bu 2
Default: on
.UNINDENT
.UNINDENT
.UNINDENT
.INDENT 0.0
.TP
.B Enable gzip support. When enabled Varnish request compressed objects from the backend and store them compressed. If a client does not support gzip encoding Varnish will uncompress compressed objects on demand. Varnish will also rewrite the Accept\-Encoding header of clients indicating support for gzip to:
Accept\-Encoding: gzip
.UNINDENT
.sp
Clients that do not support gzip will have their Accept\-Encoding header removed. For more information on how gzip is implemented please see the chapter on gzip in the Varnish reference.
.sp
When gzip support is disabled the variables beresp.do_gzip and beresp.do_gunzip have no effect in VCL.
.SS http_max_hdr
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: header lines
.IP \(bu 2
Default: 64
.IP \(bu 2
Minimum: 32
.IP \(bu 2
Maximum: 65535
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Maximum number of HTTP header lines we allow in {req|resp|bereq|beresp}.http (obj.http is autosized to the exact number of headers).
Cheap, ~20 bytes, in terms of workspace memory.
Note that the first line occupies five header lines.
.SS http_range_support
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bool
.IP \(bu 2
Default: on
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Enable support for HTTP Range headers.
.SS http_req_hdr_len
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 8k
.IP \(bu 2
Minimum: 40b
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Maximum length of any HTTP client request header we will allow.  The limit is inclusive its continuation lines.
.SS http_req_size
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 32k
.IP \(bu 2
Minimum: 0.25k
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Maximum number of bytes of HTTP client request we will deal with.  This is a limit on all bytes up to the double blank line which ends the HTTP request.
The memory for the request is allocated from the client workspace (param: workspace_client) and this parameter limits how much of that the request is allowed to take up.
.SS http_resp_hdr_len
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 8k
.IP \(bu 2
Minimum: 40b
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Maximum length of any HTTP backend response header we will allow.  The limit is inclusive its continuation lines.
.SS http_resp_size
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 32k
.IP \(bu 2
Minimum: 0.25k
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Maximum number of bytes of HTTP backend response we will deal with.  This is a limit on all bytes up to the double blank line which ends the HTTP response.
The memory for the response is allocated from the backend workspace (param: workspace_backend) and this parameter limits how much of that the response is allowed to take up.
.SS idle_send_timeout
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 60.000
.IP \(bu 2
Minimum: 0.000
.IP \(bu 2
Flags: delayed
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Send timeout for individual pieces of data on client connections. May get extended if \(aqsend_timeout\(aq applies.
.sp
When this timeout is hit, the session is closed.
.sp
See the man page for \fIsetsockopt(2)\fP or \fIsocket(7)\fP under \fBSO_SNDTIMEO\fP for more information.
.SS listen_depth
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: connections
.IP \(bu 2
Default: 1024
.IP \(bu 2
Minimum: 0
.IP \(bu 2
Flags: must_restart
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Listen queue depth.
.SS lru_interval
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 2.000
.IP \(bu 2
Minimum: 0.000
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Grace period before object moves on LRU list.
Objects are only moved to the front of the LRU list if they have not been moved there already inside this timeout period.  This reduces the amount of lock operations necessary for LRU list access.
.SS max_esi_depth
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: levels
.IP \(bu 2
Default: 5
.IP \(bu 2
Minimum: 0
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Maximum depth of esi:include processing.
.SS max_restarts
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: restarts
.IP \(bu 2
Default: 4
.IP \(bu 2
Minimum: 0
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Upper limit on how many times a request can restart.
.SS max_retries
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: retries
.IP \(bu 2
Default: 4
.IP \(bu 2
Minimum: 0
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Upper limit on how many times a backend fetch can retry.
.SS max_vcl
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Default: 100
.IP \(bu 2
Minimum: 0
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Threshold of loaded VCL programs.  (VCL labels are not counted.)  Parameter max_vcl_handling determines behaviour.
.SS max_vcl_handling
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Default: 1
.IP \(bu 2
Minimum: 0
.IP \(bu 2
Maximum: 2
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Behaviour when attempting to exceed max_vcl loaded VCL.
.INDENT 0.0
.IP \(bu 2
0 \- Ignore max_vcl parameter.
.IP \(bu 2
1 \- Issue warning.
.IP \(bu 2
2 \- Refuse loading VCLs.
.UNINDENT
.SS nuke_limit
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: allocations
.IP \(bu 2
Default: 50
.IP \(bu 2
Minimum: 0
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Maximum number of objects we attempt to nuke in order to make space for a object body.
.SS pcre_match_limit
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Default: 10000
.IP \(bu 2
Minimum: 1
.UNINDENT
.UNINDENT
.UNINDENT
.sp
The limit for the number of calls to the internal match() function in pcre_exec().
.sp
(See: PCRE_EXTRA_MATCH_LIMIT in pcre docs.)
.sp
This parameter limits how much CPU time regular expression matching can soak up.
.SS pcre_match_limit_recursion
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Default: 20
.IP \(bu 2
Minimum: 1
.UNINDENT
.UNINDENT
.UNINDENT
.sp
The recursion depth\-limit for the internal match() function in a pcre_exec().
.sp
(See: PCRE_EXTRA_MATCH_LIMIT_RECURSION in pcre docs.)
.sp
This puts an upper limit on the amount of stack used by PCRE for certain classes of regular expressions.
.sp
We have set the default value low in order to prevent crashes, at the cost of possible regexp matching failures.
.sp
Matching failures will show up in the log as VCL_Error messages with regexp errors \-27 or \-21.
.sp
Testcase r01576 can be useful when tuning this parameter.
.SS ping_interval
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 3
.IP \(bu 2
Minimum: 0
.IP \(bu 2
Flags: must_restart
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Interval between pings from parent to child.
Zero will disable pinging entirely, which makes it possible to attach a debugger to the child.
.SS pipe_sess_max
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: connections
.IP \(bu 2
Default: 0
.IP \(bu 2
Minimum: 0
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Maximum number of sessions dedicated to pipe transactions.
.SS pipe_timeout
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 60.000
.IP \(bu 2
Minimum: 0.000
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Idle timeout for PIPE sessions. If nothing have been received in either direction for this many seconds, the session is closed.
.SS pool_req
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Default: 10,100,10
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Parameters for per worker pool request memory pool.
.sp
The three numbers are:
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.TP
.B \fImin_pool\fP
minimum size of free pool.
.TP
.B \fImax_pool\fP
maximum size of free pool.
.TP
.B \fImax_age\fP
max age of free element.
.UNINDENT
.UNINDENT
.UNINDENT
.SS pool_sess
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Default: 10,100,10
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Parameters for per worker pool session memory pool.
.sp
The three numbers are:
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.TP
.B \fImin_pool\fP
minimum size of free pool.
.TP
.B \fImax_pool\fP
maximum size of free pool.
.TP
.B \fImax_age\fP
max age of free element.
.UNINDENT
.UNINDENT
.UNINDENT
.SS pool_vbo
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Default: 10,100,10
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Parameters for backend object fetch memory pool.
.sp
The three numbers are:
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.TP
.B \fImin_pool\fP
minimum size of free pool.
.TP
.B \fImax_pool\fP
maximum size of free pool.
.TP
.B \fImax_age\fP
max age of free element.
.UNINDENT
.UNINDENT
.UNINDENT
.SS prefer_ipv6
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bool
.IP \(bu 2
Default: off
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Prefer IPv6 address when connecting to backends which have both IPv4 and IPv6 addresses.
.SS rush_exponent
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: requests per request
.IP \(bu 2
Default: 3
.IP \(bu 2
Minimum: 2
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
How many parked request we start for each completed request on the object.
NB: Even with the implict delay of delivery, this parameter controls an exponential increase in number of worker threads.
.SS send_timeout
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 600.000
.IP \(bu 2
Minimum: 0.000
.IP \(bu 2
Flags: delayed
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Total timeout for ordinary HTTP1 responses. Does not apply to some internally generated errors and pipe mode.
.sp
When \(aqidle_send_timeout\(aq is hit while sending an HTTP1 response, the timeout is extended unless the total time already taken for sending the response in its entirety exceeds this many seconds.
.sp
When this timeout is hit, the session is closed
.SS shortlived
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 10.000
.IP \(bu 2
Minimum: 0.000
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Objects created with (ttl+grace+keep) shorter than this are always put in transient storage.
.SS sigsegv_handler
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bool
.IP \(bu 2
Default: on
.IP \(bu 2
Flags: must_restart
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Install a signal handler which tries to dump debug information on segmentation faults, bus errors and abort signals.
.SS syslog_cli_traffic
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bool
.IP \(bu 2
Default: on
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Log all CLI traffic to syslog(LOG_INFO).
.SS tcp_fastopen
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bool
.IP \(bu 2
Default: off
.IP \(bu 2
Flags: must_restart
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Enable TCP Fast Open extension.
.SS tcp_keepalive_intvl
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: platform dependent
.IP \(bu 2
Minimum: 1.000
.IP \(bu 2
Maximum: 100.000
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
The number of seconds between TCP keep\-alive probes. Ignored for Unix domain sockets.
.SS tcp_keepalive_probes
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: probes
.IP \(bu 2
Default: platform dependent
.IP \(bu 2
Minimum: 1
.IP \(bu 2
Maximum: 100
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
The maximum number of TCP keep\-alive probes to send before giving up and killing the connection if no response is obtained from the other end. Ignored for Unix domain sockets.
.SS tcp_keepalive_time
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: platform dependent
.IP \(bu 2
Minimum: 1.000
.IP \(bu 2
Maximum: 7200.000
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
The number of seconds a connection needs to be idle before TCP begins sending out keep\-alive probes. Ignored for Unix domain sockets.
.SS thread_pool_add_delay
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 0.000
.IP \(bu 2
Minimum: 0.000
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Wait at least this long after creating a thread.
.sp
Some (buggy) systems may need a short (sub\-second) delay between creating threads.
Set this to a few milliseconds if you see the \(aqthreads_failed\(aq counter grow too much.
.sp
Setting this too high results in insufficient worker threads.
.SS thread_pool_destroy_delay
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 1.000
.IP \(bu 2
Minimum: 0.010
.IP \(bu 2
Flags: delayed, experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Wait this long after destroying a thread.
.sp
This controls the decay of thread pools when idle(\-ish).
.SS thread_pool_fail_delay
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 0.200
.IP \(bu 2
Minimum: 0.010
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Wait at least this long after a failed thread creation before trying to create another thread.
.sp
Failure to create a worker thread is often a sign that  the end is near, because the process is running out of some resource.  This delay tries to not rush the end on needlessly.
.sp
If thread creation failures are a problem, check that thread_pool_max is not too high.
.sp
It may also help to increase thread_pool_timeout and thread_pool_min, to reduce the rate at which treads are destroyed and later recreated.
.SS thread_pool_max
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: threads
.IP \(bu 2
Default: 5000
.IP \(bu 2
Minimum: thread_pool_min
.IP \(bu 2
Flags: delayed
.UNINDENT
.UNINDENT
.UNINDENT
.sp
The maximum number of worker threads in each pool.
.sp
Do not set this higher than you have to, since excess worker threads soak up RAM and CPU and generally just get in the way of getting work done.
.SS thread_pool_min
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: threads
.IP \(bu 2
Default: 100
.IP \(bu 2
Minimum: 5
.IP \(bu 2
Maximum: thread_pool_max
.IP \(bu 2
Flags: delayed
.UNINDENT
.UNINDENT
.UNINDENT
.sp
The minimum number of worker threads in each pool.
.sp
Increasing this may help ramp up faster from low load situations or when threads have expired.
.sp
Technical minimum is 5 threads, but this parameter is strongly recommended to be at least 10
.SS thread_pool_reserve
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: threads
.IP \(bu 2
Default: 0
.IP \(bu 2
Maximum: 95% of thread_pool_min
.IP \(bu 2
Flags: delayed
.UNINDENT
.UNINDENT
.UNINDENT
.sp
The number of worker threads reserved for vital tasks in each pool.
.sp
Tasks may require other tasks to complete (for example, client requests may require backend requests, http2 sessions require streams, which require requests). This reserve is to ensure that lower priority tasks do not prevent higher priority tasks from running even under high load.
.sp
The effective value is at least 5 (the number of internal priority classes), irrespective of this parameter.
Default is 0 to auto\-tune (5% of thread_pool_min).
Minimum is 1 otherwise, maximum is 95% of thread_pool_min.
.SS thread_pool_stack
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: sysconf(_SC_THREAD_STACK_MIN)
.IP \(bu 2
Minimum: 16k
.IP \(bu 2
Flags: delayed
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Worker thread stack size.
This will likely be rounded up to a multiple of 4k (or whatever the page_size might be) by the kernel.
.sp
The required stack size is primarily driven by the depth of the call\-tree. The most common relevant determining factors in varnish core code are GZIP (un)compression, ESI processing and regular expression matches. VMODs may also require significant amounts of additional stack. The nesting depth of VCL subs is another factor, although typically not predominant.
.sp
The stack size is per thread, so the maximum total memory required for worker thread stacks is in the order of size = thread_pools x thread_pool_max x thread_pool_stack.
.sp
Thus, in particular for setups with many threads, keeping the stack size at a minimum helps reduce the amount of memory required by Varnish.
.sp
On the other hand, thread_pool_stack must be large enough under all circumstances, otherwise varnish will crash due to a stack overflow. Usually, a stack overflow manifests itself as a segmentation fault (aka segfault / SIGSEGV) with the faulting address being near the stack pointer (sp).
.sp
Unless stack usage can be reduced, thread_pool_stack must be increased when a stack overflow occurs. Setting it in 150%\-200% increments is recommended until stack overflows cease to occur.
.SS thread_pool_timeout
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 300.000
.IP \(bu 2
Minimum: 10.000
.IP \(bu 2
Flags: delayed, experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Thread idle threshold.
.sp
Threads in excess of thread_pool_min, which have been idle for at least this long, will be destroyed.
.SS thread_pool_watchdog
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 60.000
.IP \(bu 2
Minimum: 0.100
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Thread queue stuck watchdog.
.sp
If no queued work have been released for this long, the worker process panics itself.
.SS thread_pools
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: pools
.IP \(bu 2
Default: 2
.IP \(bu 2
Minimum: 1
.IP \(bu 2
Maximum: defined when Varnish is built
.IP \(bu 2
Flags: delayed, experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Number of worker thread pools.
.sp
Increasing the number of worker pools decreases lock contention. Each worker pool also has a thread accepting new connections, so for very high rates of incoming new connections on systems with many cores, increasing the worker pools may be required.
.sp
Too many pools waste CPU and RAM resources, and more than one pool for each CPU is most likely detrimental to performance.
.sp
Can be increased on the fly, but decreases require a restart to take effect, unless the drop_pools experimental debug flag is set.
.SS thread_queue_limit
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Default: 20
.IP \(bu 2
Minimum: 0
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Permitted request queue length per thread\-pool.
.sp
This sets the number of requests we will queue, waiting for an available thread.  Above this limit sessions will be dropped instead of queued.
.SS thread_stats_rate
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: requests
.IP \(bu 2
Default: 10
.IP \(bu 2
Minimum: 0
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Worker threads accumulate statistics, and dump these into the global stats counters if the lock is free when they finish a job (request/fetch etc.)
This parameters defines the maximum number of jobs a worker thread may handle, before it is forced to dump its accumulated stats into the global counters.
.SS timeout_idle
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 5.000
.IP \(bu 2
Minimum: 0.000
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Idle timeout for client connections.
.sp
A connection is considered idle until we have received the full request headers.
.sp
This parameter is particularly relevant for HTTP1 keepalive  connections which are closed unless the next request is received before this timeout is reached.
.SS timeout_linger
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 0.050
.IP \(bu 2
Minimum: 0.000
.IP \(bu 2
Flags: experimental
.UNINDENT
.UNINDENT
.UNINDENT
.sp
How long the worker thread lingers on an idle session before handing it over to the waiter.
When sessions are reused, as much as half of all reuses happen within the first 100 msec of the previous request completing.
Setting this too high results in worker threads not doing anything for their keep, setting it too low just means that more sessions take a detour around the waiter.
.SS vcc_acl_pedantic
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bool
.IP \(bu 2
Default: off
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Insist that network numbers used in ACLs have an all\-zero host part, e.g. make 1.2.3.4/24 an error.
With this option set to off (the default), the host part of network numbers is being fixed to all\-zeroes (e.g. the above changed to 1.2.3.0/24), a warning is output during VCL compilation and any ACL entry hits are logged with the fixed address as "fixed: ..." after the original VCL entry.
With this option set to on, any ACL entries with non\-zero host parts cause VCL compilation to fail.
.SS vcc_allow_inline_c
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bool
.IP \(bu 2
Default: off
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Allow inline C code in VCL.
.SS vcc_err_unref
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bool
.IP \(bu 2
Default: on
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Unreferenced VCL objects result in error.
.SS vcc_unsafe_path
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bool
.IP \(bu 2
Default: on
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Allow \(aq/\(aq in vmod & include paths.
Allow \(aqimport ... from ...\(aq.
.SS vcl_cooldown
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 600.000
.IP \(bu 2
Minimum: 1.000
.UNINDENT
.UNINDENT
.UNINDENT
.sp
How long a VCL is kept warm after being replaced as the active VCL (granularity approximately 30 seconds).
.SS vcl_path
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Default: /opt/varnish/etc/varnish:/opt/varnish/share/varnish/vcl
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Directory (or colon separated list of directories) from which relative VCL filenames (vcl.load and include) are to be found.  By default Varnish searches VCL files in both the system configuration and shared data directories to allow packages to drop their VCL files in a standard location where relative includes would work.
.SS vmod_path
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Default: /opt/varnish/lib/varnish/vmods
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Directory (or colon separated list of directories) where VMODs are to be found.
.SS vsl_buffer
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 4k
.IP \(bu 2
Minimum: vsl_reclen + 12 bytes
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Bytes of (req\-/backend\-)workspace dedicated to buffering VSL records.
When this parameter is adjusted, most likely workspace_client and workspace_backend will have to be adjusted by the same amount.
.sp
Setting this too high costs memory, setting it too low will cause more VSL flushes and likely increase lock\-contention on the VSL mutex.
.SS vsl_mask
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Default: \-Debug,\-ObjProtocol,\-ObjStatus,\-ObjReason,\-ObjHeader,\-VCL_trace,\-WorkThread,\-Hash,\-VfpAcct,\-H2RxHdr,\-H2RxBody,\-H2TxHdr,\-H2TxBody
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Mask individual VSL messages from being logged.
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.TP
.B \fIdefault\fP
Set default value
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Use +/\- prefix in front of VSL tag name to unmask/mask individual VSL messages.
.SS vsl_reclen
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 255b
.IP \(bu 2
Minimum: 16b
.IP \(bu 2
Maximum: vsl_buffer \- 12 bytes
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Maximum number of bytes in SHM log record.
.SS vsl_space
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 80M
.IP \(bu 2
Minimum: 1M
.IP \(bu 2
Maximum: 4G
.IP \(bu 2
Flags: must_restart
.UNINDENT
.UNINDENT
.UNINDENT
.sp
The amount of space to allocate for the VSL fifo buffer in the VSM memory segment.  If you make this too small, varnish{ncsa|log} etc will not be able to keep up.  Making it too large just costs memory resources.
.SS vsm_free_cooldown
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: seconds
.IP \(bu 2
Default: 60.000
.IP \(bu 2
Minimum: 10.000
.IP \(bu 2
Maximum: 600.000
.UNINDENT
.UNINDENT
.UNINDENT
.sp
How long VSM memory is kept warm after a deallocation (granularity approximately 2 seconds).
.SS vsm_space
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 1M
.IP \(bu 2
Minimum: 1M
.IP \(bu 2
Maximum: 1G
.UNINDENT
.UNINDENT
.UNINDENT
.sp
DEPRECATED: This parameter is ignored.
There is no global limit on amount of shared memory now.
.SS workspace_backend
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 64k
.IP \(bu 2
Minimum: 1k
.IP \(bu 2
Flags: delayed
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Bytes of HTTP protocol workspace for backend HTTP req/resp.  If larger than 4k, use a multiple of 4k for VM efficiency.
.SS workspace_client
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 64k
.IP \(bu 2
Minimum: 9k
.IP \(bu 2
Flags: delayed
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Bytes of HTTP protocol workspace for clients HTTP req/resp.  Use a multiple of 4k for VM efficiency.
For HTTP/2 compliance this must be at least 20k, in order to receive fullsize (=16k) frames from the client.   That usually happens only in POST/PUT bodies.  For other traffic\-patterns smaller values work just fine.
.SS workspace_session
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 0.75k
.IP \(bu 2
Minimum: 0.25k
.IP \(bu 2
Flags: delayed
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Allocation size for session structure and workspace.    The workspace is primarily used for TCP connection addresses.  If larger than 4k, use a multiple of 4k for VM efficiency.
.SS workspace_thread
.INDENT 0.0
.INDENT 3.5
.INDENT 0.0
.IP \(bu 2
Units: bytes
.IP \(bu 2
Default: 2k
.IP \(bu 2
Minimum: 0.25k
.IP \(bu 2
Maximum: 8k
.IP \(bu 2
Flags: delayed
.UNINDENT
.UNINDENT
.UNINDENT
.sp
Bytes of auxiliary workspace per thread.
This workspace is used for certain temporary data structures during the operation of a worker thread.
One use is for the IO\-vectors used during delivery. Setting this parameter too low may increase the number of writev() syscalls, setting it too high just wastes space.  ~0.1k + UIO_MAXIOV * sizeof(struct iovec) (typically = ~16k for 64bit) is considered the maximum sensible value under any known circumstances (excluding exotic vmod use).
.SH EXIT CODES
.sp
Varnish and bundled tools will, in most cases, exit with one of the
following codes
.INDENT 0.0
.IP \(bu 2
\fI0\fP OK
.IP \(bu 2
\fI1\fP Some error which could be system\-dependent and/or transient
.IP \(bu 2
\fI2\fP Serious configuration / parameter error \- retrying with the same
configuration / parameters is most likely useless
.UNINDENT
.sp
The \fIvarnishd\fP master process may also OR its exit code
.INDENT 0.0
.IP \(bu 2
with \fI0x20\fP when the \fIvarnishd\fP child process died,
.IP \(bu 2
with \fI0x40\fP when the \fIvarnishd\fP child process was terminated by a
signal and
.IP \(bu 2
with \fI0x80\fP when a core was dumped.
.UNINDENT
.SH SEE ALSO
.INDENT 0.0
.IP \(bu 2
\fIvarnishlog(1)\fP
.IP \(bu 2
\fIvarnishhist(1)\fP
.IP \(bu 2
\fIvarnishncsa(1)\fP
.IP \(bu 2
\fIvarnishstat(1)\fP
.IP \(bu 2
\fIvarnishtop(1)\fP
.IP \(bu 2
\fIvarnish\-cli(7)\fP
.IP \(bu 2
\fIvcl(7)\fP
.UNINDENT
.SH HISTORY
.sp
The \fIvarnishd\fP daemon was developed by Poul\-Henning Kamp in cooperation
with Verdens Gang AS and Varnish Software.
.sp
This manual page was written by Dag\-Erling Smørgrav with updates by
Stig Sandbeck Mathisen <\fI\%ssm@debian.org\fP>, Nils Goroll and others.
.SH COPYRIGHT
.sp
This document is licensed under the same licence as Varnish
itself. See LICENCE for details.
.INDENT 0.0
.IP \(bu 2
Copyright (c) 2007\-2015 Varnish Software AS
.UNINDENT
.\" Generated by docutils manpage writer.
.