2 * BGP-specific error messages.
3 * Copyright (C) 2018 Cumulus Networks, Inc.
6 * This program is free software; you can redistribute it and/or modify it
7 * under the terms of the GNU General Public License as published by the Free
8 * Software Foundation; either version 2 of the License, or (at your option)
11 * This program is distributed in the hope that it will be useful, but WITHOUT
12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
16 * You should have received a copy of the GNU General Public License along
17 * with this program; see the file COPYING; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
24 #include "bgp_errors.h"
26 /* clang-format off */
27 static struct log_ref ferr_bgp_err
[] = {
29 .code
= BGP_ERR_ATTR_FLAG
,
30 .title
= "BGP attribute flag is incorrect",
31 .description
= "BGP attribute flag is set to the wrong value (Optional/Transitive/Partial)",
32 .suggestion
= "Determine the source of the attribute and determine why the attribute flag has been set incorrectly"
35 .code
= BGP_ERR_ATTR_LEN
,
36 .title
= "BGP attribute length is incorrect",
37 .description
= "BGP attribute length is incorrect",
38 .suggestion
= "Determine the source of the attribute and determine why the attribute length has been set incorrectly"
41 .code
= BGP_ERR_ATTR_ORIGIN
,
42 .title
= "BGP attribute origin value invalid",
43 .description
= "BGP attribute origin value is invalid",
44 .suggestion
= "Determine the source of the attribute and determine why the origin attribute has been set incorrectly"
47 .code
= BGP_ERR_ATTR_MAL_AS_PATH
,
48 .title
= "BGP as path is invalid",
49 .description
= "BGP as path has been malformed",
50 .suggestion
= "Determine the source of the update and determine why the as path has been set incorrectly"
53 .code
= BGP_ERR_ATTR_FIRST_AS
,
54 .title
= "BGP as path first as is invalid",
55 .description
= "BGP update has invalid first as in as path",
56 .suggestion
= "Determine the source of the update and determine why the as path first as value has been set incorrectly"
59 .code
= BGP_ERR_ATTR_PMSI_TYPE
,
60 .title
= "BGP PMSI tunnel attribute type is invalid",
61 .description
= "BGP update has invalid type for PMSI tunnel",
62 .suggestion
= "Determine the source of the update and determine why the PMSI tunnel attribute type has been set incorrectly"
65 .code
= BGP_ERR_ATTR_PMSI_LEN
,
66 .title
= "BGP PMSI tunnel attribute length is invalid",
67 .description
= "BGP update has invalid length for PMSI tunnel",
68 .suggestion
= "Determine the source of the update and determine why the PMSI tunnel attribute length has been set incorrectly"
71 .code
= BGP_ERR_PEER_GROUP
,
72 .title
= "BGP peergroup operated on in error",
73 .description
= "BGP operating on peer-group instead of peers included",
74 .suggestion
= "Ensure the config doesn't contain peergroups contained within peergroups"
77 .code
= BGP_ERR_PEER_DELETE
,
78 .title
= "BGP failed to delete peer structure",
79 .description
= "BGP was unable to delete peer structure when address-family removed",
80 .suggestion
= "Determine if all expected peers are removed and restart FRR if not. Most likely a bug"
83 .code
= BGP_ERR_TABLE_CHUNK
,
84 .title
= "BGP failed to get table chunk memory",
85 .description
= "BGP unable to get chunk memory for table manager",
86 .suggestion
= "Ensure there is adequate memory on the device to support the table requirements"
89 .code
= BGP_ERR_MACIP_LEN
,
90 .title
= "BGP received MACIP with invalid IP addr len",
91 .description
= "BGP received MACIP with invalid IP addr len from Zebra",
92 .suggestion
= "Verify MACIP entries inserted in Zebra are correct. Most likely a bug"
95 .code
= BGP_ERR_LM_ERROR
,
96 .title
= "BGP received invalid label manager message",
97 .description
= "BGP received invalid label manager message from label manager",
98 .suggestion
= "Label manager sent invalid essage to BGP for wrong protocol, instance, etc. Most likely a bug"
101 .code
= BGP_ERR_JSON_MEM_ERROR
,
102 .title
= "BGP unable to allocate memory for JSON output",
103 .description
= "BGP attempted to generate JSON output and was unable to allocate the memory required",
104 .suggestion
= "Ensure that the device has adequate memory to support the required functions"
107 .code
= BGP_ERR_UPDGRP_ATTR_LEN
,
108 .title
= "BGP update had attributes too long to send",
109 .description
= "BGP attempted to send an update but the attributes were too long to fit",
110 .suggestion
= "Most likely a bug. If the problem persists, report the problem for troubleshooting"
113 .code
= BGP_ERR_UPDGRP_CREATE
,
114 .title
= "BGP update group creation failed",
115 .description
= "BGP attempted to create an update group but was unable to",
116 .suggestion
= "Most likely a bug. If the problem persists, report the problem for troubleshooting"
119 .code
= BGP_ERR_UPDATE_SND
,
120 .title
= "BGP error creating update packet",
121 .description
= "BGP attempted to create an update packet but was unable to",
122 .suggestion
= "Most likely a bug. If the problem persists, report the problem for troubleshooting"
125 .code
= BGP_ERR_PKT_OPEN
,
126 .title
= "BGP error receiving open packet",
127 .description
= "BGP received an open from a peer that was invalid",
128 .suggestion
= "Determine the sending peer and correct his invalid open packet"
131 .code
= BGP_ERR_SND_FAIL
,
132 .title
= "BGP error sending to peer",
133 .description
= "BGP attempted to respond to open from a peer and failed",
134 .suggestion
= "BGP attempted to respond to an open and could not sene the packet. Check local IP address for source"
137 .code
= BGP_ERR_INVALID_STATUS
,
138 .title
= "BGP error receiving from peer",
139 .description
= "BGP received an update from a peer but status was incorrect",
140 .suggestion
= "Most likely a bug. If the problem persists, report the problem for troubleshooting"
143 .code
= BGP_ERR_UPDATE_RCV
,
144 .title
= "BGP error receiving update packet",
145 .description
= "BGP received an invalid update packet",
146 .suggestion
= "Determine the source of the update and resolve the invalid update being sent"
149 .code
= BGP_ERR_NO_CAP
,
150 .title
= "BGP error due to capability not enabled",
151 .description
= "BGP attempted a function that did not have the capability enabled",
152 .suggestion
= "Enable the capability if this functionality is desired"
155 .code
= BGP_ERR_NOTIFY_RCV
,
156 .title
= "BGP error receiving notify message",
157 .description
= "BGP unable to process notification message",
158 .suggestion
= "BGP notify received while in stopped state. If the problem persists, report for troubleshooting"
161 .code
= BGP_ERR_KEEP_RCV
,
162 .title
= "BGP error receiving keepalive packet",
163 .description
= "BGP unable to process keepalive packet",
164 .suggestion
= "BGP keepalive received while in stopped state. If the problem persists, report for troubleshooting"
167 .code
= BGP_ERR_RFSH_RCV
,
168 .title
= "BGP error receiving route refresh message",
169 .description
= "BGP unable to process route refresh message",
170 .suggestion
= "BGP route refresh received while in stopped state. If the problem persists, report for troubleshooting"},
172 .code
= BGP_ERR_CAP_RCV
,
173 .title
= "BGP error capability message",
174 .description
= "BGP unable to process received capability",
175 .suggestion
= "BGP capability message received while in stopped state. If the problem persists, report for troubleshooting"
178 .code
= BGP_ERR_NH_UPD
,
179 .title
= "BGP error with nexthopo update",
180 .description
= "BGP unable to process nexthop update",
181 .suggestion
= "BGP received nexthop update but nexthop is not reachable in this bgp instance. Report for troubleshooting"
184 .code
= BGP_ERR_LABEL
,
185 .title
= "Failure to apply label",
186 .description
= "BGP attempted to attempted to apply a label but could not",
187 .suggestion
= "Most likely a bug. If the problem persists, report the problem for troubleshooting"
190 .code
= BGP_ERR_MULTIPATH
,
191 .title
= "Multipath specified is invalid",
192 .description
= "BGP was started with an invalid ecmp/multipath value",
193 .suggestion
= "Correct the ecmp/multipath value supplied when starting the BGP daemon"
196 .code
= BGP_ERR_PKT_PROCESS
,
197 .title
= "Failure to process a packet",
198 .description
= "BGP attempted to process a received packet but could not",
199 .suggestion
= "Most likely a bug. If the problem persists, report the problem for troubleshooting"
202 .code
= BGP_ERR_CONNECT
,
203 .title
= "Failure to connect to peer",
204 .description
= "BGP attempted to send open to peer but couldn't connect",
205 .suggestion
= "Most likely a bug. If the problem persists, report the problem for troubleshooting"
209 .title
= "BGP FSM issue",
210 .description
= "BGP neighbor transition problem",
211 .suggestion
= "Most likely a bug. If the problem persists, report the problem for troubleshooting"
215 .title
= "BGP VNI creation issue",
216 .description
= "BGP could not create a new VNI",
217 .suggestion
= "Most likely a bug. If the problem persists, report the problem for troubleshooting"
220 .code
= BGP_ERR_NO_DFLT
,
221 .title
= "BGP default instance missing",
222 .description
= "BGP could not find default instance",
223 .suggestion
= "Define a default instance of BGP since some feature requires it's existence"
226 .code
= BGP_ERR_VTEP_INVALID
,
227 .title
= "BGP remote VTEP invalid",
228 .description
= "BGP remote VTEP is invalid and cannot be used",
229 .suggestion
= "Correct remote VTEP configuration or resolve the source of the problem"
232 .code
= BGP_ERR_ES_INVALID
,
233 .title
= "BGP ES route error",
234 .description
= "BGP ES route incorrect, learned both local and remote",
235 .suggestion
= "Correct configuration or addressing so that same not learned both local and remote"
238 .code
= BGP_ERR_EVPN_ROUTE_DELETE
,
239 .title
= "BGP EVPN route delete error",
240 .description
= "BGP attempted to delete an EVPN route and failed",
241 .suggestion
= "Most likely a bug. If the problem persists, report the problem for troubleshooting"
244 .code
= BGP_ERR_EVPN_FAIL
,
245 .title
= "BGP EVPN install/uninstall error",
246 .description
= "BGP attempted to install or uninstall an EVPN prefix and failed",
247 .suggestion
= "Most likely a bug. If the problem persists, report the problem for troubleshooting"
250 .code
= BGP_ERR_EVPN_ROUTE_INVALID
,
251 .title
= "BGP EVPN route received with invalid contents",
252 .description
= "BGP received an EVPN route with invalid contents",
253 .suggestion
= "Determine the source of the EVPN route and resolve whatever is causing invalid contents"
256 .code
= BGP_ERR_EVPN_ROUTE_CREATE
,
257 .title
= "BGP EVPN route create error",
258 .description
= "BGP attempted to create an EVPN route and failed",
259 .suggestion
= "Most likely a bug. If the problem persists, report the problem for troubleshooting"
262 .code
= BGP_ERR_ES_CREATE
,
263 .title
= "BGP EVPN ES entry create error",
264 .description
= "BGP attempted to create an EVPN ES entry and failed",
265 .suggestion
= "Most likely a bug. If the problem persists, report the problem for troubleshooting"
268 .code
= BGP_ERR_MULTI_INSTANCE
,
269 .title
= "BGP config multi-instance issue",
270 .description
= "BGP configuration attempting multiple instances without enabling the feature",
271 .suggestion
= "Correct the configuration so that bgp multiple-instance is enabled if desired"
274 .code
= BGP_ERR_EVPN_AS_MISMATCH
,
275 .title
= "BGP AS configuration issue",
276 .description
= "BGP configuration attempted for a different AS than currently configured",
277 .suggestion
= "Correct the configuration so that the correct BGP AS number is used"
280 .code
= BGP_ERR_EVPN_INSTANCE_MISMATCH
,
281 .title
= "BGP EVPN AS and process name mismatch",
282 .description
= "BGP configuration has AS and process name mismatch",
283 .suggestion
= "Correct the configuration so that the BGP AS number and instance name are consistent"
286 .code
= BGP_ERR_FLOWSPEC_PACKET
,
287 .title
= "BGP Flowspec packet processing error",
288 .description
= "The BGP flowspec subsystem has detected a error in the send or receive of a packet",
289 .suggestion
= "Gather log files from both sides of the peering relationship and open an issue"
292 .code
= BGP_ERR_FLOWSPEC_INSTALLATION
,
293 .title
= "BGP Flowspec Installation/removal Error",
294 .description
= "The BGP flowspec subsystem has detected that there was a failure for installation/removal/modification of Flowspec from the dataplane",
295 .suggestion
= "Gather log files from the router and open an issue, Restart FRR"
301 /* clang-format on */
303 void bgp_error_init(void)
305 log_ref_add(ferr_bgp_err
);