From 4a7d61409d3301f694558b7b3f980085a6fa77d8 Mon Sep 17 00:00:00 2001 From: Anuradha Karuppiah Date: Mon, 20 Jul 2020 08:37:46 -0700 Subject: [PATCH] zebra: add ESI to the "show evpn mac vni <> mac <> json" output Sample output - ============= anuradhak-VirtualBox# anuradhak-VirtualBox# show evpn mac vni 1000 mac 00:00:00:00:00:22 json { "00:00:00:00:00:22":{ "type":"remote", "remoteVtep":"0.0.0.0", "localSequence":0, "remoteSequence":0, "detectionCount":0, "isDuplicate":false, "syncNeighCount":0, "esi":"03:44:38:39:ff:ff:02:00:00:02", >>>>>>>>>>>>>>>> "neighbors":"none" } } Signed-off-by: Anuradha Karuppiah --- zebra/zebra_vxlan.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/zebra/zebra_vxlan.c b/zebra/zebra_vxlan.c index 0154cda0c5..ff09b48dcf 100644 --- a/zebra/zebra_vxlan.c +++ b/zebra/zebra_vxlan.c @@ -1380,6 +1380,9 @@ static void zvni_print_mac(zebra_mac_t *mac, void *ctxt, json_object *json) thread_buf, sizeof(thread_buf), mac->hold_timer)); + if (mac->es) + json_object_string_add(json_mac, "esi", + mac->es->esi_str); /* print all the associated neigh */ if (!listcount(mac->neigh_list)) json_object_string_add(json_mac, "neighbors", "none"); -- 2.39.5