diff options
author | 2017-09-28 07:44:52 +0530 | |
---|---|---|
committer | 2017-10-04 14:31:45 -0700 | |
commit | f0b9e1845fa02690492a8a37069a633f15eafdf4 (patch) | |
tree | 10edc77bc40464cf2fbb5910d01ee42cde038c45 | |
parent | c65d2e761955affbdb76fc31ebb188ac492c31ca (diff) |
Fix the cgnapt pipeline stat issues
Change-Id: I58d4a1b6c47fa204a8af67c725b22f797ec19755
Signed-off-by: Deepak S <deepak.s@linux.intel.com>
-rw-r--r-- | VNFs/vCGNAPT/pipeline/pipeline_cgnapt_be.c | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/VNFs/vCGNAPT/pipeline/pipeline_cgnapt_be.c b/VNFs/vCGNAPT/pipeline/pipeline_cgnapt_be.c index f578587e..aaf558e6 100644 --- a/VNFs/vCGNAPT/pipeline/pipeline_cgnapt_be.c +++ b/VNFs/vCGNAPT/pipeline/pipeline_cgnapt_be.c @@ -10502,6 +10502,16 @@ void all_cgnapt_stats(char *buf) len += sprintf(buf + len, "egress %" PRIu64 "\n", p_nat->enaptedPktCount); len += sprintf(buf + len, "arpicmp pkts %" PRIu64 "\n", p_nat->arpicmpPktCount); + printf("pipeline %d stats:\n", p_nat->pipeline_num); + printf("Received %" PRIu64 ",", p_nat->receivedPktCount); + printf("Missed %" PRIu64 ",", p_nat->missedPktCount); + printf("Dropped %" PRIu64 ",", p_nat->naptDroppedPktCount); + printf("Translated %" PRIu64 ",", p_nat->naptedPktCount); + printf("ingress %" PRIu64 ",", p_nat->inaptedPktCount); + printf("egress %" PRIu64 "\n", p_nat->enaptedPktCount); + printf("arpicmp pkts %" PRIu64 "\n", p_nat->arpicmpPktCount); + + #ifdef CGNAPT_DEBUGGING len += sprintf(buf + len, "\n Drop detail 1:%" PRIu64 ",", @@ -10546,6 +10556,15 @@ void all_cgnapt_stats(char *buf) len += sprintf(buf + len, "egress %" PRIu64 "\n", enaptedPktCount); len += sprintf(buf + len, "arpicmp pkts %" PRIu64 "\n", arpicmpPktCount); + printf("\nTotal pipeline stats:\n"); + printf("Received %" PRIu64 ",", receivedPktCount); + printf("Missed %" PRIu64 ",", missedPktCount); + printf("Dropped %" PRIu64 ",", naptDroppedPktCount); + printf("Translated %" PRIu64 ",", naptedPktCount); + printf("ingress %" PRIu64 ",", inaptedPktCount); + printf("egress %" PRIu64 "\n", enaptedPktCount); + printf("arpicmp pkts %" PRIu64 "\n", arpicmpPktCount); + if (!rest_api_supported()) printf("%s\n", buf); } |