1VARNISHLOG(1)                                                    VARNISHLOG(1)
2
3
4

NAME

6       varnishlog - Display Varnish logs
7

SYNOPSIS

9       varnishlog  [-a] [-b] [-C] [-c] [-D] [-d] [-I regex] [-i tag] [-k keep]
10       [-n varnish_name] [-o] [-P file] [-r file] [-s num] [-u] [-V] [-w file]
11       [-X regex] [-x tag] [tag regex]
12

DESCRIPTION

14       The  varnishlog  utility  reads  and presents varnishd(1) shared memory
15       logs.
16
17       The following options are available:
18
19       -a     When writing to a file, append to it rather than overwrite it.
20
21       -b     Include log entries which result from communication with a back‐
22              end  server.  If neither -b nor -c is specified, varnishlog acts
23              as if they both were.
24
25       -C     Ignore case when matching regular expressions.
26
27       -c     Include log entries  which  result  from  communication  with  a
28              client.   If  neither -b nor -c is specified, varnishlog acts as
29              if they both were.
30
31       -D     Daemonize.
32
33       -d     Process old log entries on startup.  Normally,  varnishlog  will
34              only  process  entries  which  are  written  to the log after it
35              starts.
36
37       -I regex
38              Include log entries which match the  specified  regular  expres‐
39              sion.   If  neither  -I nor -i is specified, all log entries are
40              included.
41
42       -i tag Include log entries with the specified tag.  If neither  -I  nor
43              -i is specified, all log entries are included.
44
45       -k num Only show the first num log records.
46
47       -n     Specifies  the  name  of the varnishd instance to get logs from.
48              If -n is not specified, the host name is used.
49
50       -o     Group log entries by request ID.  This has no effect when  writ‐
51              ing to a file using the -w option.
52
53       -P file
54              Write the process's PID to the specified file.
55
56       -r file
57              Read log entries from file instead of shared memory.
58
59       -s num Skip the first num log records.
60
61       -u     Unbuffered output.
62
63       -V     Display the version number and exit.
64
65       -w file
66              Write  log entries to file instead of displaying them.  The file
67              will be overwritten unless the -a option was specified. If  var‐
68              nishlog  receives  a  SIGHUP  while  writing  to a file, it will
69              reopen the file, allowing the old one to be rotated away.
70
71       -X regex
72              Exclude log entries which match the  specified  regular  expres‐
73              sion.
74
75       -x tag Exclude log entries with the specified tag.
76
77       If  the  -o  option  was  specified, an additional tag and regex may be
78       specified to select only requests which generated a log entry with  the
79       given tag whose contents match the given regex.
80

TAGS

82       The following log entry tags are currently defined:
83
84       · Backend
85
86       · BackendClose
87
88       · BackendOpen
89
90       · BackendReuse
91
92       · BackendXID
93
94       · CLI
95
96       · ClientAddr
97
98       · Debug
99
100       · Error
101
102       · ExpBan
103
104       · ExpKill
105
106       · ExpPick
107
108       · Hit
109
110       · HitPass
111
112       · HttpError
113
114       · HttpGarbage
115
116       · Length
117
118       · ObjHeader
119
120       · ObjLostHeader
121
122       · ObjProtocol
123
124       · ObjRequest
125
126       · ObjResponse
127
128       · ObjStatus
129
130       · ObjURL
131
132       · ReqEnd
133
134       · ReqStart
135
136       · RxHeader
137
138       · RxLostHeader
139
140       · RxProtocol
141
142       · RxRequest
143
144       · RxResponse
145
146       · RxStatus
147
148       · RxURL
149
150       · SessionClose
151
152       · SessionOpen
153
154       · StatAddr
155
156       · StatSess
157
158       · TTL
159
160       · TxHeader
161
162       · TxLostHeader
163
164       · TxProtocol
165
166       · TxRequest
167
168       · TxResponse
169
170       · TxStatus
171
172       · TxURL
173
174       · VCL_acl
175
176       · VCL_call
177
178       · VCL_return
179
180       · VCL_trace
181
182       · WorkThread
183

EXAMPLES

185       The  following  command  line  simply  copies  all log entries to a log
186       file::
187
188       $ varnishlog -w /var/log/varnish.log
189
190       The following command line  reads  that  same  log  file  and  displays
191       requests for the front page::
192
193       $ varnishlog -r /var/log/varnish.log -c -o RxURL '^/$'
194

SEE ALSO

196       · varnishd(1)
197
198       · varnishhist(1)
199
200       · varnishncsa(1)
201
202       · varnishstat(1)
203
204       · varnishtop(1)
205

HISTORY

207       The   varnishlog   utility   was   developed   by   Poul-Henning   Kamp
208       ⟨phk@phk.freebsd.dk⟩ in cooperation with Verdens Gang AS, Linpro AS and
209       Varnish Software.  This manual page was initially written by Dag-Erling
210       Smørgrav.
211
213       This document is licensed under the same licence as Varnish itself. See
214       LICENCE for details.
215
216       · Copyright (c) 2006 Verdens Gang AS
217
218       · Copyright (c) 2006-2008 Linpro AS
219
220       · Copyright (c) 2008-2010 Redpill Linpro AS
221
222       · Copyright (c) 2010 Varnish Software AS
223

AUTHOR

225       Dag-Erling Smørgrav, Per Buer
226
227
228
229
2300.2                               2010-05-31                     VARNISHLOG(1)
Impressum