From 37bb7aca30eb0997820e888dcd171f7f3c86bffa Mon Sep 17 00:00:00 2001 From: Philippe Guibert Date: Thu, 2 May 2019 09:35:29 +0200 Subject: bgpd: add bfd event trace that bfd event trace is visible when 'debug bgp neighbor-event' is enabled. Signed-off-by: Philippe Guibert --- bgpd/bgp_bfd.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'bgpd/bgp_bfd.c') diff --git a/bgpd/bgp_bfd.c b/bgpd/bgp_bfd.c index dadf124ee..f1737ff9f 100644 --- a/bgpd/bgp_bfd.c +++ b/bgpd/bgp_bfd.c @@ -276,6 +276,11 @@ static void bgp_bfd_peer_status_update(struct peer *peer, int status) bfd_info->status = status; bfd_info->last_update = bgp_clock(); + if (status != old_status) { + if (BGP_DEBUG(neighbor_events, NEIGHBOR_EVENTS)) + zlog_debug("[%s]: BFD %s", peer->host, + bfd_get_status_str(status)); + } if ((status == BFD_STATUS_DOWN) && (old_status == BFD_STATUS_UP)) { peer->last_reset = PEER_DOWN_BFD_DOWN; BGP_EVENT_ADD(peer, BGP_Stop); -- cgit v1.2.3