]> git.puffer.fish Git - mirror/frr.git/commitdiff
* interface.c: Better statistics output in "show interface" command in
authorhasso <hasso>
Tue, 18 Jan 2005 13:44:35 +0000 (13:44 +0000)
committerhasso <hasso>
Tue, 18 Jan 2005 13:44:35 +0000 (13:44 +0000)
  case of /proc being used. I don't have others to test with at the
  moment.

zebra/ChangeLog
zebra/interface.c

index 8f34c94cc742449ec36a504300fc1833918235a0..b3710cf201c493fa14071b1417731ae57e91f380 100644 (file)
@@ -1,3 +1,8 @@
+2005-01-18 Hasso Tepper <hasso at quagga.net>
+
+       * interface.c: Better statistics output in "show interface" command in
+         case of /proc being used.
+
 2005-01-17 Hasso Tepper <hasso at quagga.net>
 
        * main.c: With --nl-bufsize argument is required.
index 391997bf608afa6a76b8c0198f2acae8309c5c92..0b206d321f26747176cefc1ff72f516d0ad9d490 100644 (file)
@@ -742,30 +742,32 @@ if_dump_vty (struct vty *vty, struct interface *ifp)
 
 #ifdef HAVE_PROC_NET_DEV
   /* Statistics print out using proc file system. */
-  vty_out (vty, "    input packets %lu, bytes %lu, dropped %lu,"
-          " multicast packets %lu%s",
-          ifp->stats.rx_packets, ifp->stats.rx_bytes, 
-          ifp->stats.rx_dropped, ifp->stats.rx_multicast, VTY_NEWLINE);
+  vty_out (vty, "    %lu input packets (%lu multicast), %lu bytes, "
+          "%lu dropped%s",
+          ifp->stats.rx_packets, ifp->stats.rx_multicast,
+          ifp->stats.rx_bytes, ifp->stats.rx_dropped, VTY_NEWLINE);
 
-  vty_out (vty, "    input errors %lu, length %lu, overrun %lu,"
-          " CRC %lu, frame %lu, fifo %lu, missed %lu%s",
+  vty_out (vty, "    %lu input errors, %lu length, %lu overrun,"
+          " CRC %lu, frame %lu%s",
           ifp->stats.rx_errors, ifp->stats.rx_length_errors,
           ifp->stats.rx_over_errors, ifp->stats.rx_crc_errors,
-          ifp->stats.rx_frame_errors, ifp->stats.rx_fifo_errors,
+          ifp->stats.rx_frame_errors, VTY_NEWLINE);
+
+  vty_out (vty, "    %lu fifo, %lu missed%s", ifp->stats.rx_fifo_errors,
           ifp->stats.rx_missed_errors, VTY_NEWLINE);
 
-  vty_out (vty, "    output packets %lu, bytes %lu, dropped %lu%s",
+  vty_out (vty, "    %lu output packets, %lu bytes, %lu dropped%s",
           ifp->stats.tx_packets, ifp->stats.tx_bytes,
           ifp->stats.tx_dropped, VTY_NEWLINE);
 
-  vty_out (vty, "    output errors %lu, aborted %lu, carrier %lu,"
-          " fifo %lu, heartbeat %lu, window %lu%s",
+  vty_out (vty, "    %lu output errors, %lu aborted, %lu carrier,"
+          " %lu fifo, %lu heartbeat%s",
           ifp->stats.tx_errors, ifp->stats.tx_aborted_errors,
           ifp->stats.tx_carrier_errors, ifp->stats.tx_fifo_errors,
-          ifp->stats.tx_heartbeat_errors, ifp->stats.tx_window_errors,
-          VTY_NEWLINE);
+          ifp->stats.tx_heartbeat_errors, VTY_NEWLINE);
 
-  vty_out (vty, "    collisions %lu%s", ifp->stats.collisions, VTY_NEWLINE);
+  vty_out (vty, "    %lu window, %lu collisions%s",
+          ifp->stats.tx_window_errors, ifp->stats.collisions, VTY_NEWLINE);
 #endif /* HAVE_PROC_NET_DEV */
 
 #ifdef HAVE_NET_RT_IFLIST