From bcb486dd3cbce01dd1d9085006305cfcd738f9e8 Mon Sep 17 00:00:00 2001 From: Donald Sharp Date: Sat, 26 Nov 2022 09:28:14 -0500 Subject: [PATCH 1/2] zebra: Fix tracepoint changes for lttng The recent tracepoint additions in c317d3f246769e8261df0f9d1eb787bea7b5da06 did not properly setup the tracepoints for lttng. Fix this. Signed-off-by: Donald Sharp --- zebra/zebra_trace.h | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) diff --git a/zebra/zebra_trace.h b/zebra/zebra_trace.h index 49a0c8e793..374305fcda 100644 --- a/zebra/zebra_trace.h +++ b/zebra/zebra_trace.h @@ -123,6 +123,49 @@ TRACEPOINT_EVENT( ) ) +TRACEPOINT_EVENT( + frr_zebra, + netlink_tc_qdisc_change, + TP_ARGS( + struct nlmsghdr *, header, + ns_id_t, ns_id, + int, startup), + TP_FIELDS( + ctf_integer_hex(intptr_t, header, header) + ctf_integer(uint32_t, ns_id, ns_id) + ctf_integer(uint32_t, startup, startup) + ) + ) + +TRACEPOINT_EVENT( + frr_zebra, + netlink_tc_class_change, + TP_ARGS( + struct nlmsghdr *, header, + ns_id_t, ns_id, + int, startup), + TP_FIELDS( + ctf_integer_hex(intptr_t, header, header) + ctf_integer(uint32_t, ns_id, ns_id) + ctf_integer(uint32_t, startup, startup) + ) + ) + + +TRACEPOINT_EVENT( + frr_zebra, + netlink_tc_filter_change, + TP_ARGS( + struct nlmsghdr *, header, + ns_id_t, ns_id, + int, startup), + TP_FIELDS( + ctf_integer_hex(intptr_t, header, header) + ctf_integer(uint32_t, ns_id, ns_id) + ctf_integer(uint32_t, startup, startup) + ) + ) + #include #endif /* HAVE_LTTNG */ From a8a0f80b634208c878e15335948810e1d532d1e7 Mon Sep 17 00:00:00 2001 From: Donald Sharp Date: Sat, 26 Nov 2022 09:23:50 -0500 Subject: [PATCH 2/2] lib: Do not log `echo PING` commands from watchfrr Since the `echo PING` commands are from watchfrr and are sent a whole bunch when an operator has `log commands` on the amount of logging done is quite significant. Signed-off-by: Donald Sharp --- lib/vty.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/vty.c b/lib/vty.c index 5fe8d82473..352080e580 100644 --- a/lib/vty.c +++ b/lib/vty.c @@ -447,7 +447,8 @@ static int vty_command(struct vty *vty, char *buf) /* * Log non empty command lines */ - if (do_log_commands) + if (do_log_commands && + strncmp(buf, "echo PING", strlen("echo PING")) != 0) cp = buf; if (cp != NULL) { /* Skip white spaces. */