| 1 | .TH TRACERTSTATS "1" "November 2006" "tracertstats (libtrace)" "User Commands" |
|---|
| 2 | .SH NAME |
|---|
| 3 | tracertstats \- perform simple filter based analysis on a trace |
|---|
| 4 | .SH SYNOPSIS |
|---|
| 5 | .B tracertstats |
|---|
| 6 | [ -f | --filter bpf ] |
|---|
| 7 | [ -i | --interval interval ] |
|---|
| 8 | [ -c | --count count ] |
|---|
| 9 | [ -o | --output-format csv,txt,png,html ] |
|---|
| 10 | [ -m | --merge-inputs ] |
|---|
| 11 | inputuri... |
|---|
| 12 | .P |
|---|
| 13 | .B tracertstats |
|---|
| 14 | -H|--libtrace-help |
|---|
| 15 | .SH DESCRPTION |
|---|
| 16 | tracertstats takes a list of bpf expressions and outputs the number of packets |
|---|
| 17 | and bytes that match that expression every interval seconds, or count packets. |
|---|
| 18 | .TP |
|---|
| 19 | .PD 0 |
|---|
| 20 | .BI \-f " bpf-filter" |
|---|
| 21 | .TP |
|---|
| 22 | .PD |
|---|
| 23 | .BI \-\^\-filter " bpf-filter" |
|---|
| 24 | Add another "bpf filter" |
|---|
| 25 | |
|---|
| 26 | .TP |
|---|
| 27 | .PD 0 |
|---|
| 28 | .BI \-i " interval" |
|---|
| 29 | .TP |
|---|
| 30 | .PD |
|---|
| 31 | .BI \-\^\-interval " interval" |
|---|
| 32 | Output results every \fIinterval\fR seconds. |
|---|
| 33 | |
|---|
| 34 | .TP |
|---|
| 35 | .PD 0 |
|---|
| 36 | .BI \-c " count" |
|---|
| 37 | .TP |
|---|
| 38 | .PD |
|---|
| 39 | .BI \-\^\-count " count" |
|---|
| 40 | Output results every \fIcount\fR packets. |
|---|
| 41 | |
|---|
| 42 | .TP |
|---|
| 43 | .PD 0 |
|---|
| 44 | .BI \-m |
|---|
| 45 | .TP |
|---|
| 46 | .PD |
|---|
| 47 | .BI \-\^\-merge-inputs |
|---|
| 48 | Treats all inputs as a single input, resulting a single unified output rather |
|---|
| 49 | than an output for each input. Works best with traces that are consecutive to |
|---|
| 50 | create a single CSV, for instance. |
|---|
| 51 | |
|---|
| 52 | .TP |
|---|
| 53 | .PD 0 |
|---|
| 54 | .BI \-o " format" |
|---|
| 55 | .TP |
|---|
| 56 | .PD |
|---|
| 57 | .BI \-\^\-output\-format " format" |
|---|
| 58 | Selects the output format. |
|---|
| 59 | |
|---|
| 60 | .RS |
|---|
| 61 | .TP |
|---|
| 62 | txt |
|---|
| 63 | Human readable text. This is the default output format which provides output |
|---|
| 64 | easily understood by a human. This format has the disadvantage that it takes |
|---|
| 65 | up quite a bit of horizontal space. |
|---|
| 66 | |
|---|
| 67 | .TP |
|---|
| 68 | csv |
|---|
| 69 | Comma Seperated Values. This is suitable for further analysis in a spreadsheet, |
|---|
| 70 | or other program. |
|---|
| 71 | |
|---|
| 72 | .TP |
|---|
| 73 | png |
|---|
| 74 | PNG Graphic. Produces a fairly incomprehensible png graph. This relies on |
|---|
| 75 | gdc being available at compile time. |
|---|
| 76 | |
|---|
| 77 | .TP |
|---|
| 78 | html |
|---|
| 79 | This produces output suitable for display to a human in a webbrowser. |
|---|
| 80 | |
|---|
| 81 | .SH EXAMPLES |
|---|
| 82 | .nf |
|---|
| 83 | tracertstats \-\^\-filter 'host sundown' \\ |
|---|
| 84 | \-\^\-filter 'port http' \\ |
|---|
| 85 | \-\^\-filter 'port ftp or ftp-data' \\ |
|---|
| 86 | \-\^\-filter 'port smtp' \\ |
|---|
| 87 | \-\^\-filter 'tcp[tcpflags] & tcp-syn!=0' \\ |
|---|
| 88 | \-\^\-filter 'not ip' \\ |
|---|
| 89 | \-\^\-filter 'ether[0] & 1 == 1' \\ |
|---|
| 90 | \-\^\-filter 'icmp[icmptype] == icmp-unreach' \\ |
|---|
| 91 | \-\^\-output\-format html |
|---|
| 92 | erf:/traces/trace1.gz \\ |
|---|
| 93 | erf:/traces/trace2.gz |
|---|
| 94 | .fi |
|---|
| 95 | |
|---|
| 96 | .SH LINKS |
|---|
| 97 | More details about tracertstats (and libtrace) can be found at |
|---|
| 98 | http://www.wand.net.nz/trac/libtrace/wiki/UserDocumentation |
|---|
| 99 | |
|---|
| 100 | .SH SEE ALSO |
|---|
| 101 | libtrace(3), tracemerge(1), tracesplit(1), tracesplit_dir(1), tracefilter(1), |
|---|
| 102 | traceconvert(1), tracereport(1), tracepktdump(1), traceanon(1), tracesummary(1), |
|---|
| 103 | traceconvert(1), tracereplay(1), tracediff(1), traceends(1), tracetopends(1) |
|---|
| 104 | |
|---|
| 105 | .SH AUTHORS |
|---|
| 106 | Perry Lorier <perry@cs.waikato.ac.nz> |
|---|