Tutorial: Plugin monitoring

As detailed in monitoring mode T2 can either be remotely controlled by USR1/2 signals or the t2stat command. Each plugin can implement a monitoring function which will be called during monitoring or report operation.

First change the configuration of main.h to enable monitoring every second on a pcap. Just change MONINTTMPCP to 1

$ cd ~/tranalyzer2/trunk/tranalyzer2/src
$ vi tranalyzer.h
....
#define MONINTTMPCP    1
...
$

Reset your plugin directory into a priscine state and compile

$ t2build -e
...
$ t2build basicFlow tcpStates
...
$

If you did not read the tutorials before, here is the basis plugin which we will extend: tcpWin

The annonymized sample pcap can be downloaded here: annoloc2.pcap. Please extract it under your data folder: ~/data, if you not already have. Now you are all set for end report programming.

Implementing the Monitoring

If your plugin wants to contribute information to the monitoring mode, then global variables and a monitoring callback have to be added.

So open tcpWin.c in an editor and add two global variables after the tcpWinFlows definition. Look for the <– markers below. If you already completed the endreport tutorial, you only need to add the winStatG0 variable, which will be used in the differential mode to store the old value of winStatG. If this is your first plugin just add both variables: winStatG and winStatG0.

Then add in the onFlowTerminate callback the lines marked by <– to aggregate stat and winThCnt of all flows, if you did not do the endreport tutorial. Here we aggregate all flow information into global variables. Note, that

Note, that a snapshot taken by the monitoring is now only representing the terminated flows not the actually existing state in the memory. If you want that, you need to shift that code, a bit modified into the claimLayer4Information callback. We will try that later.

Now add the monitoring callback after onFlowTerminate or the pluginReport if you implemented the endreport already.

The monitoring function is called by the core at T2 initialization: T2_MON_PRI_HDR for the machine mode to output header information. At a USR1/2 interrupt: T2_MON_PRI_VAL to print data in the machine mode and T2_MON_PRI_REPORT for the report mode. If one icase is not implemented, nothing will appear. Note the DIFF_REPORT pragma, which implements the backup of the old winThCntG value.

Save the file, compile tcpWin. If compilation is error free. open main.h in I recommend to read

Now execute T2 with the -l option to redirect all endreport info to the file annoloc2_log.txt.

$ t2build tcpWin
...
$ t2 -r ~/data/annoloc2.pcap -l
%repTyp   time               dur        memUsageKB  fillSzHashMap  numFlows  numAFlows  numBFlows  numPkts  numAPkts  numBPkts  numV4Pkts  numV6Pkts  numVxPkts  numBytes  numABytes  numBBytes  numFrgV4Pkts  numFrgV6Pkts  numAlarms  rawBandwidth  globalWarn          0x0042  0x00fe  0x0806  0x8035  0x0800   0x86dd  ICMP  IGMP  TCP     UDP     GRE  ICMPv6  SCTP  winPktThCnt
USR1MR_A  1022171702.000125  0.308953   353200      2148           2156      1224       932        14548    6878      7670      14542      3          0          765516    358988     406528     31            0             0          262155.094    0x000018720202c044  0       0       3       0       14542    3       34    0     11316   3192    0    0       0     5
USR1MR_A  1022171703.000027  1.308855   355184      3882           3925      2186       1739       63742    29698     34044     63704      25         0          3351792   1550516    1801276    128           0             0          268826.906    0x000018720202c044  0       0       13      0       63704    25      163   0     49239   14324   0    0       0     28
USR1MR_A  1022171704.000334  2.309162   356212      4951           5056      2836       2220       112507   52358     60149     112438     51         0          5914518   2732728    3181790    219           0             0          268431.875    0x000018720202c044  0       0       18      0       112438   51      296   0     86741   25449   0    0       0     67
USR1MR_A  1022171705.000030  3.308858   357008      5708           5889      3325       2564       159663   74437     85226     159584     53         0          8386018   3881306    4504712    310           0             0          264000.625    0x000018720202c044  0       0       26      0       159584   53      420   0     122894  36319   0    0       0     110
USR1MR_A  1022171706.000009  4.308837   357608      6326           6576      3709       2867       206914   96379     110535    206823     56         0          10867000  5024814    5842186    406           0             0          262386.625    0x000018720202c044  0       0       35      0       206823   56      559   0     159086  47228   0    1       0     162
USR1MR_A  1022171707.000298  5.309126   358192      6954           7290      4105       3185       254975   118534    136441    254861     61         0          13387286  6177852    7209434    477           0             0          262669.312    0x000018720202d044  0       0       53      0       254861   61      671   0     196353  57885   5    3       0     209
USR1MR_A  1022171708.000102  6.308930   358820      7513           7912      4444       3468       303259   140648    162611    303123     64         0          15926886  7333416    8593470    556           0             0          263206.156    0x000018720202d044  0       0       72      0       303123   64      788   0     233879  68504   6    5       0     246
USR1MR_A  1022171709.000695  7.309523   359376      8040           8510      4795       3715       352531   163621    188910    352372     71         0          18514822  8532310    9982512    652           0             0          264265.812    0x000018720202d044  0       0       88      0       352372   71      931   0     272058  79435   6    6       0     304
USR1MR_A  1022171710.000175  8.309003   359984      8568           9093      5118       3975       403039   187245    215794    402869     75         0          21176886  9769874    11407012   749           0             0          266481.875    0x000018720202d044  0       0       95      0       402869   75      1040  0     311883  89995   13   6       0     332
USR1MR_A  1022171711.000193  9.309021   360392      9042           9617      5424       4193       451658   210068    241590    451472     77         0          23740252  10966580   12773672   833           0             0          267078.156    0x000018720202d044  0       0       109     0       451472   77      1153  0     350185  100184  13   6       0     360
USR1MR_A  1022171712.000691  10.309519  361008      9577           10191     5756       4435       501269   233143    268126    501071     77         0          26343306  12169118   14174188   928           0             0          268049.062    0x000018720202d044  0       0       121     0       501071   77      1287  0     388858  110976  13   6       0     383
USR1MR_A  1022171713.000000  11.308828  361412      10024          10720     6049       4671       551412   256611    294801    551205     77         0          28974836  13393110   15581726   1024          0             0          268974.344    0x000018720202d044  0       0       130     0       551205   77      1400  0     427957  121898  13   6       0     407
USR1MR_A  1022171714.000741  12.309569  361824      10403          11218     6335       4883       599311   279120    320191    599078     94         0          31489110  14565760   16923350   1118          0             0          268543.781    0x000018720202d044  0       0       139     0       599078   94      1515  1     465032  132594  13   6       0     442
USR1MR_A  1022171715.000263  13.309091  362228      10781          11695     6610       5085       648421   301998    346423    648174     97         0          34071594  15760864   18310730   1207          0             0          268863.219    0x000018720202d044  0       0       150     0       648174   97      1645  2     503316  143278  13   6       0     488
USR1MR_A  1022171716.000269  14.309097  362832      11252          12238     6926       5312       698406   325185    373221    698150     101        0          36699500  16971514   19727986   1301          0             0          269511.562    0x000018720202d044  0       0       155     0       698150   101     1773  2     542399  154047  13   6       0     513
USR1MR_A  1022171717.000932  15.309760  363048      11638          12738     7212       5526       747344   347703    399641    747071     107        0          39275032  18149678   21125354   1394          0             0          269802.594    0x000018720202d044  0       0       166     0       747071   107     1903  2     580632  164609  13   6       0     542
USR1MR_A  1022171718.000200  16.309028  363476      11947          13165     7452       5713       795044   369576    425468    794746     128        0          41776324  19287976   22488348   1482          0             0          269423.312    0x000018720202d044  0       0       170     0       794746   128     2024  2     617673  175137  16   9       0     576
USR1MR_A  1022171719.000284  17.309112  363912      12321          13637     7738       5899       843307   391558    451749    842995     130        0          44308618  20431084   23877534   1579          0             0          269352.250    0x000018720202d044  0       0       182     0       842995   130     2158  2     655118  185808  16   9       0     610
USR1MR_A  1022171720.001095  18.309923  364348      12718          14168     8044       6124       892928   414179    478749    892594     134        0          46919904  21611042   25308862   1672          0             0          269816.062    0x000018720202d044  0       0       200     0       892594   134     2271  2     694162  196252  16   9       0     642
USR1MR_A  1022171721.000640  19.309468  364568      13124          14674     8326       6348       943094   437143    505951    942754     134        0          49559680  22809626   26750054   1765          0             0          270355.562    0x000018720202d044  0       0       206     0       942754   134     2396  2     733607  206842  16   9       0     751
USR1MR_A  1022171722.000427  20.309255  365008      13583          15236     8653       6583       990269   459039    531230    989914     138        0          52038278  23949778   28088500   1857          0             0          269668.500    0x000018720202d044  0       0       217     0       989914   138     2513  2     769832  217664  16   9       0     791
USR1MR_A  1022171723.000058  21.308886  365460      13940          15721     8929       6792       1039141  481689    557452    1038772    146        0          54616822  25137106   29479716   1956          0             0          269752.812    0x000018720202d044  0       0       223     0       1038772  146     2627  2     807994  228251  16   9       0     832
USR1MR_A  1022171724.000127  22.308955  365912      14352          16296     9250       7046       1089230  504717    584513    1088852    149        0          57251068  26338174   30912894   2044          0             0          270287.719    0x000018720202d044  0       0       229     0       1088852  149     2734  2     847258  238961  16   10      0     887
USR1MR_A  1022171725.000274  23.309102  366352      14728          16840     9569       7271       1139138  527597    611541    1138735    167        0          59878972  27534014   32344958   2137          0             0          270699.000    0x000018720202d044  0       0       236     0       1138735  167     2873  5     886260  249717  16   10      0     950
USR1MR_A  1022171726.000378  24.309206  366584      15021          17337     9850       7487       1187905  549919    637986    1187489    173        0          62444278  28699542   33744736   2227          0             0          270729.438    0x000018720202d044  0       0       243     0       1187489  173     3006  10    924247  260351  16   10      0     1026
$

You will notice your monitoring column. Wasn’t so difficult, right? Now remove tcpStates and rerun T2:

$ t2build -u tcpStates

Plugin 'tcpStates'


BUILD SUCCESSFUL

$ t2 -r ~/data/annoloc2.pcap -l
%repTyp   time               dur        memUsageKB  fillSzHashMap  numFlows  numAFlows  numBFlows  numPkts  numAPkts  numBPkts  numV4Pkts  numV6Pkts  numVxPkts  numBytes  numABytes  numBBytes  numFrgV4Pkts  numFrgV6Pkts  numAlarms  rawBandwidth  globalWarn          0x0042  0x00fe  0x0806  0x8035  0x0800   0x86dd  ICMP  IGMP  TCP     UDP     GRE  ICMPv6  SCTP  winPktThCnt
USR1MR_A  1022171702.000125  0.308953   353212      2156           2156      1224       932        14548    6878      7670      14542      3          0          765516    358988     406528     31            0             0          262155.094    0x000018720202c044  0       0       3       0       14542    3       34    0     11316   3192    0    0       0     0
USR1MR_A  1022171703.000027  1.308855   355196      3922           3922      2184       1738       63742    29698     34044     63704      25         0          3351792   1550516    1801276    128           0             0          268826.906    0x000018720202c044  0       0       13      0       63704    25      163   0     49239   14324   0    0       0     0
USR1MR_A  1022171704.000334  2.309162   356224      5034           5034      2823       2211       112507   52358     60149     112438     51         0          5914518   2732728    3181790    219           0             0          268431.875    0x000018720202c044  0       0       18      0       112438   51      296   0     86741   25449   0    0       0     0
USR1MR_A  1022171705.000030  3.308858   357028      5850           5850      3303       2547       159663   74437     85226     159584     53         0          8386018   3881306    4504712    310           0             0          264000.625    0x000018720202c044  0       0       26      0       159584   53      420   0     122894  36319   0    0       0     0
USR1MR_A  1022171706.000009  4.308837   357624      6508           6508      3672       2836       206914   96379     110535    206823     56         0          10867000  5024814    5842186    406           0             0          262386.625    0x000018720202c044  0       0       35      0       206823   56      559   0     159086  47228   0    1       0     0
USR1MR_A  1022171707.000298  5.309126   358220      7193           7193      4053       3140       254975   118534    136441    254861     61         0          13387286  6177852    7209434    477           0             0          262669.312    0x000018720202d044  0       0       53      0       254861   61      671   0     196353  57885   5    3       0     0
USR1MR_A  1022171708.000102  6.308930   358852      7788           7788      4378       3410       303259   140648    162611    303123     64         0          15926886  7333416    8593470    556           0             0          263206.156    0x000018720202d044  0       0       72      0       303123   64      788   0     233879  68504   6    5       0     0
USR1MR_A  1022171709.000695  7.309523   359424      8367           8367      4717       3650       352531   163621    188910    352372     71         0          18514822  8532310    9982512    652           0             0          264265.812    0x000018720202d044  0       0       88      0       352372   71      931   0     272058  79435   6    6       0     0
USR1MR_A  1022171710.000175  8.309003   360032      8931           8931      5029       3902       403039   187245    215794    402869     75         0          21176886  9769874    11407012   749           0             0          266481.875    0x000018720202d044  0       0       95      0       402869   75      1040  0     311883  89995   13   6       0     0
USR1MR_A  1022171711.000193  9.309021   360640      9447           9447      5331       4116       451658   210068    241590    451472     77         0          23740252  10966580   12773672   833           0             0          267078.156    0x000018720202d044  0       0       109     0       451472   77      1153  0     350185  100184  13   6       0     0
USR1MR_A  1022171712.000691  10.309519  361060      10012          10012     5658       4354       501269   233143    268126    501071     77         0          26343306  12169118   14174188   928           0             0          268049.062    0x000018720202d044  0       0       121     0       501071   77      1287  0     388858  110976  13   6       0     0
USR1MR_A  1022171713.000000  11.308828  361680      10529          10529     5944       4585       551412   256610    294802    551205     77         0          28974836  13393048   15581788   1024          0             0          268974.344    0x000018720202d044  0       0       130     0       551205   77      1400  0     427957  121898  13   6       0     0
USR1MR_A  1022171714.000741  12.309569  362096      11000          11000     6217       4783       599311   279118    320193    599078     94         0          31489110  14565652   16923458   1118          0             0          268543.781    0x000018720202d044  0       0       139     0       599078   94      1515  1     465032  132594  13   6       0     0
USR1MR_A  1022171715.000263  13.309091  362512      11452          11452     6477       4975       648421   301996    346425    648174     97         0          34071594  15760756   18310838   1207          0             0          268863.219    0x000018720202d044  0       0       150     0       648174   97      1645  2     503316  143278  13   6       0     0
USR1MR_A  1022171716.000269  14.309097  363132      11979          11979     6784       5195       698406   325183    373223    698150     101        0          36699500  16971406   19728094   1301          0             0          269511.562    0x000018720202d044  0       0       155     0       698150   101     1773  2     542399  154047  13   6       0     0
USR1MR_A  1022171717.000932  15.309760  363584      12458          12458     7057       5401       747344   347700    399644    747071     107        0          39275032  18149516   21125516   1394          0             0          269802.594    0x000018720202d044  0       0       166     0       747071   107     1903  2     580632  164609  13   6       0     0
USR1MR_A  1022171718.000200  16.309028  364016      12868          12868     7287       5581       795044   369573    425471    794746     128        0          41776324  19287814   22488510   1482          0             0          269423.312    0x000018720202d044  0       0       170     0       794746   128     2024  2     617673  175137  16   9       0     0
USR1MR_A  1022171719.000284  17.309112  364456      13319          13319     7562       5757       843307   391555    451752    842995     130        0          44308618  20430922   23877696   1579          0             0          269352.250    0x000018720202d044  0       0       182     0       842995   130     2158  2     655118  185808  16   9       0     0
USR1MR_A  1022171720.001095  18.309923  364916      13826          13826     7856       5970       892928   414176    478752    892594     134        0          46919904  21610880   25309024   1672          0             0          269816.062    0x000018720202d044  0       0       200     0       892594   134     2271  2     694162  196252  16   9       0     0
USR1MR_A  1022171721.000640  19.309468  365356      14312          14312     8129       6183       943094   437140    505954    942754     134        0          49559680  22809464   26750216   1765          0             0          270355.562    0x000018720202d044  0       0       206     0       942754   134     2396  2     733607  206842  16   9       0     0
USR1MR_A  1022171722.000427  20.309255  365812      14851          14851     8443       6408       990269   459036    531233    989914     138        0          52038278  23949616   28088662   1857          0             0          269668.500    0x000018720202d044  0       0       217     0       989914   138     2513  2     769832  217664  16   9       0     0
USR1MR_A  1022171723.000058  21.308886  366280      15306          15306     8702       6604       1039141  481685    557456    1038772    146        0          54616822  25136890   29479932   1956          0             0          269752.812    0x000018720202d044  0       0       223     0       1038772  146     2627  2     807994  228251  16   9       0     0
USR1MR_A  1022171724.000127  22.308955  366740      15858          15858     9011       6847       1089230  504712    584518    1088852    149        0          57251068  26337904   30913164   2044          0             0          270287.719    0x000018720202d044  0       0       229     0       1088852  149     2734  2     847258  238961  16   10      0     0
USR1MR_A  1022171725.000274  23.309102  367180      16375          16375     9312       7063       1139138  527592    611546    1138735    167        0          59878972  27533744   32345228   2137          0             0          270699.000    0x000018720202d044  0       0       236     0       1138735  167     2873  5     886260  249717  16   10      0     0
USR1MR_A  1022171726.000378  24.309206  367668      16848          16848     9581       7267       1187905  549914    637991    1187489    173        0          62444278  28699272   33745006   2227          0             0          270729.438    0x000018720202d044  0       0       243     0       1187489  173     3006  10    924247  260351  16   10      0     0
$

Comparing the column winPktThCnt you notice that without tcpStates plugin all output of your plugin is 0. Why? Because no flow terminated yet, the timeout is by default 3minutes, the processing time of the pcap is only 0.5sec. So one way is to reduce the flow timeout: FLOW_TIMEOUT in tranalyzer.h, or to move the code to claimLayer4Information as indicated above. So delete or comment out the two lines we added in onFlowTerminate and add the following with <– marked lines in the claimLayer4Information function.

recompile and rerun T2:

$ t2build tcpWin
...
BUILD SUCCESSFUL

$ t2 -r ~/data/annoloc2.pcap -l
%repTyp	time	dur	memUsageKB	fillSzHashMap	numFlows	numAFlows	numBFlows	numPkts	numAPkts	numBPkts	numV4Pkts	numV6Pkts	numVxPkts	numBytes	numABytes	numBBytes	numFrgV4Pkts	numFrgV6Pkts	numAlarms	rawBandwidth	globalWarn	0x0042	0x00fe	0x0806	0x8035	0x0800	0x86dd	ICMP	IGMP	TCP	UDP	GRE	ICMPv6	SCTP	winPktThCnt	
USR1MR_A	1022171702.000125	0.308953	353160	2156	2156	1224	932	14548	6878	7670	14542	3	0	765516	358988	406528	31	0	0	262155.094	0x000018720202c044	0	0	3	0	14542	3	34	0	11316	3192	0	0	0	25	
USR1MR_A	1022171703.000027	1.308855	355148	3922	3922	2184	1738	63742	29698	34044	63704	25	0	3351792	1550516	1801276	128	0	0	268826.906	0x000018720202c044	0	0	13	0	63704	25	163	0	49239	14324	0	0	0	129	
USR1MR_A	1022171704.000334	2.309162	356172	5034	5034	2823	2211	112507	52358	60149	112438	51	0	5914518	2732728	3181790	219	0	0	268431.875	0x000018720202c044	0	0	18	0	112438	51	296	0	86741	25449	0	0	0	255	
USR1MR_A	1022171705.000030	3.308858	356976	5850	5850	3303	2547	159663	74437	85226	159584	53	0	8386018	3881306	4504712	310	0	0	264000.625	0x000018720202c044	0	0	26	0	159584	53	420	0	122894	36319	0	0	0	376	
USR1MR_A	1022171706.000009	4.308837	357576	6508	6508	3672	2836	206914	96379	110535	206823	56	0	10867000	5024814	5842186	406	0	0	262386.625	0x000018720202c044	0	0	35	0	206823	56	559	0	159086	47228	0	1	0	486	
USR1MR_A	1022171707.000298	5.309126	358168	7193	7193	4053	3140	254975	118534	136441	254861	61	0	13387286	6177852	7209434	477	0	0	262669.312	0x000018720202d044	0	0	53	0	254861	61	671	0	196353	57885	5	3	0	597	
USR1MR_A	1022171708.000102	6.308930	358800	7788	7788	4378	3410	303259	140648	162611	303123	64	0	15926886	7333416	8593470	556	0	0	263206.156	0x000018720202d044	0	0	72	0	303123	64	788	0	233879	68504	6	5	0	687	
USR1MR_A	1022171709.000695	7.309523	359372	8367	8367	4717	3650	352531	163621	188910	352372	71	0	18514822	8532310	9982512	652	0	0	264265.812	0x000018720202d044	0	0	88	0	352372	71	931	0	272058	79435	6	6	0	809	
USR1MR_A	1022171710.000175	8.309003	359984	8931	8931	5029	3902	403039	187245	215794	402869	75	0	21176886	9769874	11407012	749	0	0	266481.875	0x000018720202d044	0	0	95	0	402869	75	1040	0	311883	89995	13	6	0	905	
USR1MR_A	1022171711.000193	9.309021	360588	9447	9447	5331	4116	451658	210068	241590	451472	77	0	23740252	10966580	12773672	833	0	0267078.156	0x000018720202d044	0	0	109	0	451472	77	1153	0	350185	100184	13	6	0	989	
USR1MR_A	1022171712.000691	10.309519	361008	10012	10012	5658	4354	501269	233143	268126	501071	77	0	26343306	12169118	14174188	928	0	0268049.062	0x000018720202d044	0	0	121	0	501071	77	1287	0	388858	110976	13	6	0	1070	
USR1MR_A	1022171713.000000	11.308828	361628	10529	10529	5944	4585	551412	256610	294802	551205	77	0	28974836	13393048	15581788	1024	0	0268974.344	0x000018720202d044	0	0	130	0	551205	77	1400	0	427957	121898	13	6	0	1159	
USR1MR_A	1022171714.000741	12.309569	362044	11000	11000	6217	4783	599311	279118	320193	599078	94	0	31489110	14565652	16923458	1118	0	0268543.781	0x000018720202d044	0	0	139	0	599078	94	1515	1	465032	132594	13	6	0	1274	
USR1MR_A	1022171715.000263	13.309091	362460	11452	11452	6477	4975	648421	301996	346425	648174	97	0	34071594	15760756	18310838	1207	0	0268863.219	0x000018720202d044	0	0	150	0	648174	97	1645	2	503316	143278	13	6	0	1372	
USR1MR_A	1022171716.000269	14.309097	363080	11979	11979	6784	5195	698406	325183	373223	698150	101	0	36699500	16971406	19728094	1301	0	0269511.562	0x000018720202d044	0	0	155	0	698150	101	1773	2	542399	154047	13	6	0	1444	
USR1MR_A	1022171717.000932	15.309760	363532	12458	12458	7057	5401	747344	347700	399644	747071	107	0	39275032	18149516	21125516	1394	0	0269802.594	0x000018720202d044	0	0	166	0	747071	107	1903	2	580632	164609	13	6	0	1522	
USR1MR_A	1022171718.000200	16.309028	363964	12868	12868	7287	5581	795044	369573	425471	794746	128	0	41776324	19287814	22488510	1482	0	0269423.312	0x000018720202d044	0	0	170	0	794746	128	2024	2	617673	175137	16	9	0	1619	
USR1MR_A	1022171719.000284	17.309112	364404	13319	13319	7562	5757	843307	391555	451752	842995	130	0	44308618	20430922	23877696	1579	0	0269352.250	0x000018720202d044	0	0	182	0	842995	130	2158	2	655118	185808	16	9	0	1696	
USR1MR_A	1022171720.001095	18.309923	364864	13826	13826	7856	5970	892928	414176	478752	892594	134	0	46919904	21610880	25309024	1672	0	0269816.062	0x000018720202d044	0	0	200	0	892594	134	2271	2	694162	196252	16	9	0	1766	
USR1MR_A	1022171721.000640	19.309468	365304	14312	14312	8129	6183	943094	437140	505954	942754	134	0	49559680	22809464	26750216	1765	0	0270355.562	0x000018720202d044	0	0	206	0	942754	134	2396	2	733607	206842	16	9	0	1849	
USR1MR_A	1022171722.000427	20.309255	365760	14851	14851	8443	6408	990269	459036	531233	989914	138	0	52038278	23949616	28088662	1857	0	0269668.500	0x000018720202d044	0	0	217	0	989914	138	2513	2	769832	217664	16	9	0	1931	
USR1MR_A	1022171723.000058	21.308886	366228	15306	15306	8702	6604	1039141	481685	557456	1038772	146	0	54616822	25136890	29479932	1956	0	0269752.812	0x000018720202d044	0	0	223	0	1038772	146	2627	2	807994	228251	16	9	0	2015	
USR1MR_A	1022171724.000127	22.308955	366688	15858	15858	9011	6847	1089230	504712	584518	1088852	149	0	57251068	26337904	30913164	2044	0	0270287.719	0x000018720202d044	0	0	229	0	1088852	149	2734	2	847258	238961	16	10	0	2117	
USR1MR_A	1022171725.000274	23.309102	367128	16375	16375	9312	7063	1139138	527592	611546	1138735	167	0	59878972	27533744	32345228	2137	0	0270699.000	0x000018720202d044	0	0	236	0	1138735	167	2873	5	886260	249717	16	10	0	2240	
USR1MR_A	1022171726.000378	24.309206	367616	16848	16848	9581	7267	1187905	549914	637991	1187489	173	0	62444278	28699272	33745006	2227	0	0270729.438	0x000018720202d044	0	0	243	0	1187489	173	3006	10	924247	260351	16	10	0	2359
$

See? Play a bit around with the different types of reporting and change the config in tranalyzer.h and main.h as being discussed in monitoring mode. And compare the results to the endreport. Also try to run t2 on an interface, and play around with the different time base modes and remote control options in main.h. At this point I like to refer to the tutorial monitoring.

Have fun!