summaryrefslogtreecommitdiff
path: root/zebra/zebra_router.c
diff options
context:
space:
mode:
Diffstat (limited to 'zebra/zebra_router.c')
-rw-r--r--zebra/zebra_router.c19
1 files changed, 19 insertions, 0 deletions
diff --git a/zebra/zebra_router.c b/zebra/zebra_router.c
index 7f911164cd..0c4d16906e 100644
--- a/zebra/zebra_router.c
+++ b/zebra/zebra_router.c
@@ -126,6 +126,25 @@ unsigned long zebra_router_score_proto(uint8_t proto, unsigned short instance)
return cnt;
}
+void zebra_router_show_table_summary(struct vty *vty)
+{
+ struct zebra_router_table *zrt;
+
+ vty_out(vty,
+ "VRF NS ID VRF ID AFI SAFI Table Count\n");
+ vty_out(vty,
+ "---------------------------------------------------------------------------\n");
+ RB_FOREACH (zrt, zebra_router_table_head, &zrouter.tables) {
+ rib_table_info_t *info = route_table_get_info(zrt->table);
+
+ vty_out(vty, "%-16s%5d %9d %7s %15s %8d %10lu\n", info->zvrf->vrf->name,
+ zrt->ns_id, info->zvrf->vrf->vrf_id,
+ afi2str(zrt->afi), safi2str(zrt->safi),
+ zrt->tableid,
+ zrt->table->count);
+ }
+}
+
void zebra_router_sweep_route(void)
{
struct zebra_router_table *zrt;