ns: Add statistics for some events
The following counters are added to the ns.nsvc counter group:
lost.alive The number of missing ALIVE ACK messages
lost.reset The number of missing RESET ACK messages
The following items are added to the ns.nsvc stat item group:
alive.delay The time in ms between sending ALIVE and
receiving the next ALIVE ACK
Sponsored-by: On-Waves ehf
diff --git a/src/gb/gprs_ns_vty.c b/src/gb/gprs_ns_vty.c
index 155e1e9..5a951dc 100644
--- a/src/gb/gprs_ns_vty.c
+++ b/src/gb/gprs_ns_vty.c
@@ -167,8 +167,10 @@
inet_ntoa(nsvc->ip.bts_addr.sin_addr),
ntohs(nsvc->ip.bts_addr.sin_port));
vty_out(vty, "%s", VTY_NEWLINE);
- if (stats)
+ if (stats) {
vty_out_rate_ctr_group(vty, " ", nsvc->ctrg);
+ vty_out_stat_item_group(vty, " ", nsvc->statg);
+ }
}
static void dump_ns(struct vty *vty, struct gprs_ns_inst *nsi, int stats)