]> git.puffer.fish Git - mirror/frr.git/commitdiff
zebra: add nexthop counter to 'show zebra dplane' command 16410/head
authorPhilippe Guibert <philippe.guibert@6wind.com>
Wed, 17 Jul 2024 09:28:10 +0000 (11:28 +0200)
committerPhilippe Guibert <philippe.guibert@6wind.com>
Wed, 17 Jul 2024 09:58:22 +0000 (11:58 +0200)
The nexthop updates counter value was never displayed.
Add it.

> # show zebra dplane
> Zebra dataplane:
> Route updates:            7673010
> Route update errors:      0
> Nexthop updates:          1100
> Nexthop update errors:    0
> [..]

Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
zebra/zebra_dplane.c

index 0844b346723bf92d415a0b74d8cf6dcf7fd7aecc..1cee1ebb9331530ebb85ef3738323812332e0031 100644 (file)
@@ -6003,6 +6003,14 @@ int dplane_show_helper(struct vty *vty, bool detailed)
        vty_out(vty, "Zebra dataplane:\nRoute updates:            %"PRIu64"\n",
                incoming);
        vty_out(vty, "Route update errors:      %"PRIu64"\n", errs);
+
+       incoming = atomic_load_explicit(&zdplane_info.dg_nexthops_in,
+                                       memory_order_relaxed);
+       errs = atomic_load_explicit(&zdplane_info.dg_nexthop_errors,
+                                   memory_order_relaxed);
+       vty_out(vty, "Nexthop updates:          %" PRIu64 "\n", incoming);
+       vty_out(vty, "Nexthop update errors:    %" PRIu64 "\n", errs);
+
        vty_out(vty, "Other errors       :      %"PRIu64"\n", other_errs);
        vty_out(vty, "Route update queue limit: %"PRIu64"\n", limit);
        vty_out(vty, "Route update queue depth: %"PRIu64"\n", queued);