diff options
author | Donald Sharp <sharpd@cumulusnetworks.com> | 2018-08-16 15:15:43 +0200 |
---|---|---|
committer | Quentin Young <qlyoung@cumulusnetworks.com> | 2018-09-06 22:50:58 +0200 |
commit | f162a5b977a9edce3c04d6f85f117fb284115e06 (patch) | |
tree | 6c34f0457f6df5319feca9fbed775983b0f379e2 | |
parent | bgpd: Modify bgp_label to use flog_warn (diff) | |
download | frr-f162a5b977a9edce3c04d6f85f117fb284115e06.tar.xz frr-f162a5b977a9edce3c04d6f85f117fb284115e06.zip |
bgpd: convert bgp_nht.c to use flog_warn
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
-rw-r--r-- | bgpd/bgp_errors.c | 6 | ||||
-rw-r--r-- | bgpd/bgp_errors.h | 1 | ||||
-rw-r--r-- | bgpd/bgp_nht.c | 3 |
3 files changed, 9 insertions, 1 deletions
diff --git a/bgpd/bgp_errors.c b/bgpd/bgp_errors.c index 7d04c6310..70cdf53bd 100644 --- a/bgpd/bgp_errors.c +++ b/bgpd/bgp_errors.c @@ -152,6 +152,12 @@ static struct log_ref ferr_bgp_warn[] = { .suggestion = "Gather log information from here and remote peer and open an Issue", }, { + .code = BGP_WARN_ZEBRA_SEND, + .title = "BGP has attempted to send data to zebra and has failed to do so", + .description = "BGP has attempted to send data to zebra but has been unable to do so", + .suggestion = "Gather log data, open an Issue and restart FRR" + }, + { .code = END_FERR, } }; diff --git a/bgpd/bgp_errors.h b/bgpd/bgp_errors.h index a9f20f140..6accd4423 100644 --- a/bgpd/bgp_errors.h +++ b/bgpd/bgp_errors.h @@ -93,6 +93,7 @@ enum bgp_log_refs { BGP_WARN_EVPN_VPN_VNI, BGP_WARN_EVPN_ESI, BGP_WARN_INVALID_LABEL_STACK, + BGP_WARN_ZEBRA_SEND, }; extern void bgp_error_init(void); diff --git a/bgpd/bgp_nht.c b/bgpd/bgp_nht.c index 0c0c07995..cf055fd43 100644 --- a/bgpd/bgp_nht.c +++ b/bgpd/bgp_nht.c @@ -592,7 +592,8 @@ static void sendmsg_zebra_rnh(struct bgp_nexthop_cache *bnc, int command) bnc->bgp->vrf_id); /* TBD: handle the failure */ if (ret < 0) - zlog_warn("sendmsg_nexthop: zclient_send_message() failed"); + flog_warn(BGP_WARN_ZEBRA_SEND, + "sendmsg_nexthop: zclient_send_message() failed"); if ((command == ZEBRA_NEXTHOP_REGISTER) || (command == ZEBRA_IMPORT_ROUTE_REGISTER)) |