zebra: display DF status only for local ESs

For remote ESs it is not relevant and confuses the admin.

Local ES sample -
===============
root@torm-11:mgmt:~# vtysh -c "show evpn es 03:44:38:39:ff:ff:01:00:00:01"
ESI: 03:44:38:39:ff:ff:01:00:00:01
 Type: Local,Remote
 Interface: hostbond1
 State: up
 Bridge port: yes
 Ready for BGP: yes
 VNI Count: 10
 MAC Count: 3
 DF: status: df preference: 50000 >>>>>>>>>>>>>>>
 Nexthop group: 536870913
 VTEPs:
     27.0.0.16 df_alg: preference df_pref: 32767 nh: 268435465
     27.0.0.17 df_alg: preference df_pref: 32767 nh: 268435466

root@torm-11:mgmt:~#

Remote ES sample -
===============
root@torm-11:mgmt:~# vtysh -c "show evpn es 03:44:38:39:ff:ff:02:00:00:01"
ESI: 03:44:38:39:ff:ff:02:00:00:01
 Type: Remote
 Interface: -
 Ready for BGP: no
 VNI Count: 0
 MAC Count: 6
 DF: status: - preference: 0 >>>>>>>>>>>>>>>
 Nexthop group: 536870919
 VTEPs:
     27.0.0.18 nh: 268435464
     27.0.0.19 nh: 268435467
     27.0.0.20 nh: 268435461

root@torm-11:mgmt:~#

Signed-off-by: Anuradha Karuppiah <anuradhak@cumulusnetworks.com>
This commit is contained in:
Anuradha Karuppiah 2020-06-14 06:51:58 -07:00 committed by Anuradha Karuppiah
parent a119a429e4
commit 0109f42f86

View File

@ -2767,7 +2767,10 @@ static void zebra_evpn_es_show_entry_detail(struct vty *vty,
vty_out(vty, " VNI Count: %d\n", listcount(es->es_evi_list)); vty_out(vty, " VNI Count: %d\n", listcount(es->es_evi_list));
vty_out(vty, " MAC Count: %d\n", listcount(es->mac_list)); vty_out(vty, " MAC Count: %d\n", listcount(es->mac_list));
vty_out(vty, " DF: status: %s preference: %u\n", vty_out(vty, " DF: status: %s preference: %u\n",
(es->flags & ZEBRA_EVPNES_NON_DF) ? "non-df" : "df", !(es->flags & ZEBRA_EVPNES_LOCAL)
? "-"
: ((es->flags & ZEBRA_EVPNES_NON_DF) ? "non-df"
: "df"),
es->df_pref); es->df_pref);
vty_out(vty, " Nexthop group: %u\n", es->nhg_id); vty_out(vty, " Nexthop group: %u\n", es->nhg_id);
vty_out(vty, " VTEPs:\n"); vty_out(vty, " VTEPs:\n");