From 6ab5222f78d40cfd146674bee9f01e5cd29c4747 Mon Sep 17 00:00:00 2001 From: Donald Sharp Date: Fri, 25 May 2018 14:45:16 -0400 Subject: [PATCH] zebra: Add a breadcrumb for when we ignore a route When we receive a route that we think we own and we are not in startup conditions, then add a small debug to help debug the issue when this happens, instead of silently just ignoring the route. Signed-off-by: Donald Sharp --- zebra/rt_netlink.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/zebra/rt_netlink.c b/zebra/rt_netlink.c index 1ea2b85362..08c81d037a 100644 --- a/zebra/rt_netlink.c +++ b/zebra/rt_netlink.c @@ -310,8 +310,12 @@ static int netlink_route_change_read_unicast(struct sockaddr_nl *snl, return 0; if (!startup && is_selfroute(rtm->rtm_protocol) - && h->nlmsg_type == RTM_NEWROUTE) + && h->nlmsg_type == RTM_NEWROUTE) { + if (IS_ZEBRA_DEBUG_KERNEL) + zlog_debug("Route type: %d Received that we think we have originated, ignoring", + rtm->rtm_protocol); return 0; + } /* We don't care about change notifications for the MPLS table. */ /* TODO: Revisit this. */