.\" Automatically generated by Pod::Man 2.25 (Pod::Simple 3.16) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is turned on, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .ie \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . nr % 0 . rr F .\} .el \{\ . de IX .. .\} .\" .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2). .\" Fear. Run. Save yourself. No user-serviceable parts. . \" fudge factors for nroff and troff .if n \{\ . ds #H 0 . ds #V .8m . ds #F .3m . ds #[ \f1 . ds #] \fP .\} .if t \{\ . ds #H ((1u-(\\\\n(.fu%2u))*.13m) . ds #V .6m . ds #F 0 . ds #[ \& . ds #] \& .\} . \" simple accents for nroff and troff .if n \{\ . ds ' \& . ds ` \& . ds ^ \& . ds , \& . ds ~ ~ . ds / .\} .if t \{\ . ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u" . ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u' . ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u' . ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u' . ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u' . ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u' .\} . \" troff and (daisy-wheel) nroff accents .ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V' .ds 8 \h'\*(#H'\(*b\h'-\*(#H' .ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#] .ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H' .ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u' .ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#] .ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#] .ds ae a\h'-(\w'a'u*4/10)'e .ds Ae A\h'-(\w'A'u*4/10)'E . \" corrections for vroff .if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u' .if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u' . \" for low resolution devices (crt and lpr) .if \n(.H>23 .if \n(.V>19 \ \{\ . ds : e . ds 8 ss . ds o a . ds d- d\h'-1'\(ga . ds D- D\h'-1'\(hy . ds th \o'bp' . ds Th \o'LP' . ds ae ae . ds Ae AE .\} .rm #[ #] #H #V #F C .\" ======================================================================== .\" .IX Title "PRIVOXY-LOG-PARSER 1" .TH PRIVOXY-LOG-PARSER 1 "2016-01-22" "perl v5.14.2" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" privoxy\-log\-parser \- A parser and syntax\-highlighter for Privoxy log messages .SH "SYNOPSIS" .IX Header "SYNOPSIS" \&\fBprivoxy-log-parser\fR [\fB\-\-accept\-unknown\-messages\fR] [\fB\-\-html\-output\fR] [\fB\-\-no\-msecs\fR] [\fB\-\-no\-syntax\-higlighting\fR] [\fB\-\-statistics\fR] [\fB\-\-shorten\-thread\-ids\fR] [\fB\-\-show\-ineffective\-filters\fR] [\fB\-\-url\-statistics\-threshold\fR] [\fB\-\-version\fR] .SH "DESCRIPTION" .IX Header "DESCRIPTION" \&\fBprivoxy-log-parser\fR reads Privoxy log messages and .PP \&\- syntax-highlights recognized lines, .PP \&\- reformats some of them for easier comprehension, .PP \&\- filters out less useful messages, and .PP \&\- (in some cases) calculates additional information, like the compression ratio or how a filter affected the content size. .PP With \fBprivoxy-log-parser\fR you should be able to increase Privoxy's log level without getting confused by the resulting amount of output. For example for \&\*(L"debug 64\*(R" \fBprivoxy-log-parser\fR will (by default) only show messages that affect the content. If a filter doesn't cause any hits, \fBprivoxy-log-parser\fR will hide the \*(L"filter foo caused 0 hits\*(R" message. .SH "OPTIONS" .IX Header "OPTIONS" [\fB\-\-accept\-unknown\-messages\fR] Don't print warnings in case of unknown messages, just don't highlight them. .PP [\fB\-\-host\-statistics\-threshold\fR] Only show the request count for a host if it's above or equal to the given threshold. If the threshold is 0, host statistics are disabled. .PP [\fB\-\-html\-output\fR] Use \s-1HTML\s0 and \s-1CSS\s0 for the syntax highlighting. If this option is omitted, \s-1ANSI\s0 escape sequences are used unless \fB\-\-no\-syntax\-highlighting\fR is active. This option is only intended to make embedding log excerpts in web pages easier. It does not escape any input! .PP [\fB\-\-no\-msecs\fR] Don't expect milisecond resolution .PP [\fB\-\-no\-syntax\-highlighting\fR] Disable syntax-highlighting. Useful when the filtered output is piped into less in which case the \s-1ANSI\s0 control codes don't work, or if the terminal itself doesn't support the control codes. .PP [\fB\-\-shorten\-thread\-ids\fR] Shorten the thread ids to a three-digit decimal number. Note that the mapping from thread ids to shortened ids is created at run-time and thus varies with the input. .PP [\fB\-\-show\-ineffective\-filters\fR] Don't suppress log lines for filters that didn't modify the content. .PP [\fB\-\-statistics\fR] Gather various statistics instead of syntax highlighting log messages. This is an experimental feature, if the results look wrong they very well might be. Also note that the results are pretty much guaranteed to be incorrect if Privoxy and Privoxy-Log-Parser aren't in sync. .PP [\fB\-\-unbreak\-lines\-only\fR] Tries to fix lines that got messed up by a broken or interestingly configured mail client and thus are no longer recognized properly. Only fixes some breakage, but may be good enough or at least better than nothing. Doesn't do anything else, so you probably want to pipe the output into \&\fBprivoxy-log-parser\fR again. .PP [\fB\-\-url\-statistics\-threshold\fR] Only show the request count for a resource if it's above or equal to the given threshold. If the threshold is 0, \s-1URL\s0 statistics are disabled. .PP [\fB\-\-version\fR] Print version and exit. .SH "EXAMPLES" .IX Header "EXAMPLES" To monitor a log file: .PP tail \-F /usr/jails/privoxy\-jail/var/log/privoxy/privoxy.log | \fBprivoxy-log-parser\fR .PP Replace '\-F' with '\-f' if your tail implementation lacks '\-F' support or if the log won't get rotated anyway. The log file location depends on your system (Doh!). .PP To monitor Privoxy without having it write to a log file: .PP privoxy \-\-no\-daemon /usr/jails/privoxy\-jail/usr/local/etc/privoxy/config 2>&1 | \fBprivoxy-log-parser\fR .PP Again, the config file location depends on your system. Output redirection depends on your shell, the above works with bourne shells. .PP To read a processed Privoxy log file from top to bottom, letting the content scroll by slightly faster than you can read: .PP \&\fBprivoxy-log-parser\fR < /usr/jails/privoxy\-jail/var/log/privoxy/privoxy.log .PP This is probably only useful to fill screens in the background of haxor movies. .SH "CAVEATS" .IX Header "CAVEATS" Syntax highlighting with \s-1ANSI\s0 escape sequences will look strange if your background color isn't black. .PP Some messages aren't recognized yet and will not be fully highlighted. .PP \&\fBprivoxy-log-parser\fR is developed with Privoxy 3.0.7 or later in mind, using earlier Privoxy versions will probably result in an increased amount of unrecognized log lines. .PP Privoxy's log files tend to be rather large. If you use \s-1HTML\s0 highlighting some browsers can't handle them, get confused and will eventually crash because of segmentation faults or unexpected exceptions. This is a problem in the browser and not \fBprivoxy-log-parser\fR's fault. .SH "BUGS" .IX Header "BUGS" Many settings can't be controlled through command line options yet. .SH "SEE ALSO" .IX Header "SEE ALSO" \&\fIprivoxy\fR\|(1) .SH "AUTHOR" .IX Header "AUTHOR" Fabian Keil