]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
capture: display exit stats at default verbosity
authorEric Leblond <eric@regit.org>
Tue, 31 Dec 2013 14:09:10 +0000 (15:09 +0100)
committerVictor Julien <victor@inliniac.net>
Fri, 10 Jan 2014 13:47:44 +0000 (14:47 +0100)
This patch updates capture modes not using LiveDecice counters
to display per-thread exit statistics with default verbosity.

src/source-ipfw.c
src/source-napatech.c
src/source-nfq.c
src/source-pcap-file.c

index b6d2278e9434372e9f6b66f232c94b8277d678f1..3ec37787e3161a6d4cb653b29f45e5a1f9a24a01 100644 (file)
@@ -393,7 +393,7 @@ void ReceiveIPFWThreadExitStats(ThreadVars *tv, void *data)
 
     SCEnter();
 
-    SCLogInfo("(%s) Packets %" PRIu32 ", bytes %" PRIu64 "", tv->name, ptv->pkts, ptv->bytes);
+    SCLogNotice("(%s) Packets %" PRIu32 ", bytes %" PRIu64 "", tv->name, ptv->pkts, ptv->bytes);
 
     SCReturn;
 }
index 172e7f95e571cbcfebadcc5d87281f8adeb058a1..563086396057e5b5ceb7964c1076262f7334f40b 100644 (file)
@@ -317,7 +317,7 @@ void NapatechStreamThreadExitStats(ThreadVars *tv, void *data)
     if (ntv->drops > 0)
         percent = (((double) ntv->drops) / (ntv->pkts+ntv->drops)) * 100;
 
-    SCLogInfo("Stream: %lu; Packets: %"PRIu64"; Drops: %"PRIu64" (%5.2f%%); Bytes: %"PRIu64, ntv->stream_id, ntv->pkts, ntv->drops, percent, ntv->bytes);
+    SCLogNotice("Stream: %lu; Packets: %"PRIu64"; Drops: %"PRIu64" (%5.2f%%); Bytes: %"PRIu64, ntv->stream_id, ntv->pkts, ntv->drops, percent, ntv->bytes);
 }
 
 /**
index b1deefc3c8377b1c1994b30011d09254a9d06ce0..4e3b73f442eb3e277c66a174ec54a1110a5867f6 100644 (file)
@@ -1000,9 +1000,9 @@ void ReceiveNFQThreadExitStats(ThreadVars *tv, void *data) {
     NFQThreadVars *ntv = (NFQThreadVars *)data;
     NFQQueueVars *nq = NFQGetQueue(ntv->nfq_index);
 #ifdef COUNTERS
-    SCLogInfo("(%s) Pkts %" PRIu32 ", Bytes %" PRIu64 ", Errors %" PRIu32 "",
+    SCLogNotice("(%s) Pkts %" PRIu32 ", Bytes %" PRIu64 ", Errors %" PRIu32 "",
             tv->name, nq->pkts, nq->bytes, nq->errs);
-    SCLogInfo("Pkts accepted %"PRIu32", dropped %"PRIu32", replaced %"PRIu32,
+    SCLogNotice("Pkts accepted %"PRIu32", dropped %"PRIu32", replaced %"PRIu32,
             nq->accepted, nq->dropped, nq->replaced);
 #endif
 }
index 004efac06eb0a289df219f5b52b54a2d5babd549..8c7a4637bed8e14293fd78ae1b710652ab204321 100644 (file)
@@ -365,7 +365,7 @@ void ReceivePcapFileThreadExitStats(ThreadVars *tv, void *data) {
             SCLogInfo("1/%" PRIu64 "th of packets have an invalid checksum",
                       chrate);
     }
-    SCLogInfo("Pcap-file module read %" PRIu32 " packets, %" PRIu64 " bytes", ptv->pkts, ptv->bytes);
+    SCLogNotice("Pcap-file module read %" PRIu32 " packets, %" PRIu64 " bytes", ptv->pkts, ptv->bytes);
     return;
 }