summaryrefslogtreecommitdiffstats
path: root/pathd/path_errors.c
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-09 13:16:35 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-09 13:16:35 +0000
commite2bbf175a2184bd76f6c54ccf8456babeb1a46fc (patch)
treef0b76550d6e6f500ada964a3a4ee933a45e5a6f1 /pathd/path_errors.c
parentInitial commit. (diff)
downloadfrr-e2bbf175a2184bd76f6c54ccf8456babeb1a46fc.tar.xz
frr-e2bbf175a2184bd76f6c54ccf8456babeb1a46fc.zip
Adding upstream version 9.1.upstream/9.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'pathd/path_errors.c')
-rw-r--r--pathd/path_errors.c127
1 files changed, 127 insertions, 0 deletions
diff --git a/pathd/path_errors.c b/pathd/path_errors.c
new file mode 100644
index 0000000..53187fd
--- /dev/null
+++ b/pathd/path_errors.c
@@ -0,0 +1,127 @@
+// SPDX-License-Identifier: GPL-2.0-or-later
+/*
+ * pathd-specific error messages.
+ * Copyright (C) 2020 NetDEF, Inc.
+ */
+
+#include <zebra.h>
+
+#include "lib/ferr.h"
+#include "path_errors.h"
+
+/* clang-format off */
+static struct log_ref ferr_path_err[] = {
+ {
+ .code = EC_PATH_SYSTEM_CALL,
+ .title = "Thread setup error",
+ .description = "A system call for creating, or setting up PCEP module's pthread failed",
+ .suggestion = "Open an Issue with all relevant log files and restart FRR"
+ },
+ {
+ .code = EC_PATH_PCEP_PCC_INIT,
+ .title = "PCC initialization error",
+ .description = "pceplib PCC initialization call failed",
+ .suggestion = "Open an Issue with all relevant log files and restart FRR"
+ },
+ {
+ .code = EC_PATH_PCEP_PCC_FINI,
+ .title = "PCC finalization error",
+ .description = "pceplib PCC finalization call failed",
+ .suggestion = "Open an Issue with all relevant log files and restart FRR"
+ },
+ {
+ .code = EC_PATH_PCEP_PCC_CONF_UPDATE,
+ .title = "PCC configuration update error",
+ .description = "The update of the PCC configuration failed",
+ .suggestion = "Open an Issue with all relevant log files and restart FRR"
+ },
+ {
+ .code = END_FERR,
+ }
+};
+
+static struct log_ref ferr_path_warn[] = {
+ {
+ .code = EC_PATH_PCEP_LIB_CONNECT,
+ .title = "PCC connection error",
+ .description = "The PCEP module failed to connected to configured PCE",
+ .suggestion = "Check the connectivity between the PCC and the PCE"
+ },
+ {
+ .code = EC_PATH_PCEP_PROTOCOL_ERROR,
+ .title = "PCEP protocol error",
+ .description = "The PCE did not respect the PCEP protocol",
+ .suggestion = "Open an Issue with all relevant log files"
+ },
+ {
+ .code = EC_PATH_PCEP_MISSING_SOURCE_ADDRESS,
+ .title = "PCC connection error",
+ .description = "The PCEP module did not try to connect because it is missing a source address",
+ .suggestion = "Wait for the router ID to be defined or set the PCC source address in the configuration"
+ },
+ {
+ .code = EC_PATH_PCEP_RECOVERABLE_INTERNAL_ERROR,
+ .title = "Recoverable internal error",
+ .description = "Some recoverable internal error",
+ .suggestion = "Open an Issue with all relevant log files"
+ },
+ {
+ .code = EC_PATH_PCEP_UNSUPPORTED_PCEP_FEATURE,
+ .title = "Unsupported PCEP feature",
+ .description = "Received an unsupported PCEP message",
+ .suggestion = "The PCC and PCE are probably not compatible. Open an Issue with all relevant log files"
+ },
+ {
+ .code = EC_PATH_PCEP_UNEXPECTED_PCEP_MESSAGE,
+ .title = "Unexpected PCEP message",
+ .description = "The PCEP module received an unexpected PCEP message",
+ .suggestion = "Open an Issue with all relevant log files"
+ },
+ {
+ .code = EC_PATH_PCEP_UNEXPECTED_PCEPLIB_EVENT,
+ .title = "Unexpected pceplib event",
+ .description = "The PCEP module received an unexpected event from pceplib",
+ .suggestion = "Open an Issue with all relevant log files"
+ },
+ {
+ .code = EC_PATH_PCEP_UNEXPECTED_PCEP_OBJECT,
+ .title = "Unexpected PCEP object",
+ .description = "The PCEP module received an unexpected PCEP object from a PCE",
+ .suggestion = "Open an Issue with all relevant log files"
+ },
+ {
+ .code = EC_PATH_PCEP_UNEXPECTED_PCEP_TLV,
+ .title = "Unexpected PCEP TLV",
+ .description = "The PCEP module received an unexpected PCEP TLV from a PCE",
+ .suggestion = "Open an Issue with all relevant log files"
+ },
+ {
+ .code = EC_PATH_PCEP_UNEXPECTED_PCEP_ERO_SUBOBJ,
+ .title = "Unexpected PCEP ERO sub-object",
+ .description = "The PCEP module received an unexpected PCEP ERO sub-object from a PCE",
+ .suggestion = "Open an Issue with all relevant log files"
+ },
+ {
+ .code = EC_PATH_PCEP_UNEXPECTED_SR_NAI,
+ .title = "Unexpected PCEP SR segment NAI",
+ .description = "The PCEP module received an SR segment with an unsupported NAI specification from the PCE",
+ .suggestion = "Open an Issue with all relevant log files"
+ },
+ {
+ .code = EC_PATH_PCEP_COMPUTATION_REQUEST_TIMEOUT,
+ .title = "Computation request timeout",
+ .description = "The PCE did not respond in time to the PCC computation request",
+ .suggestion = "The PCE is overloaded or incompatible with the PCC, try with a different PCE"
+ },
+ {
+ .code = END_FERR,
+ }
+
+};
+/* clang-format on */
+
+void path_error_init(void)
+{
+ log_ref_add(ferr_path_err);
+ log_ref_add(ferr_path_warn);
+}