summaryrefslogtreecommitdiff
path: root/pimd/pim_cmd.c
diff options
context:
space:
mode:
authorJafar Al-Gharaibeh <Jafaral@users.noreply.github.com>2017-09-14 11:37:29 -0500
committerGitHub <noreply@github.com>2017-09-14 11:37:29 -0500
commit461b76e4ed82f3bb3f71499cfb2025959affca9b (patch)
tree920bfb0b7dda4f9b2b6c63ab6cef89472b6fa00c /pimd/pim_cmd.c
parent5b98937e2a82a372e3f0b964ea96e44211b7ec76 (diff)
parent37664928bdf161dc212d61984a754464bc0b8322 (diff)
Merge pull request #1178 from donaldsharp/pim_obfuscation
Pim debugging and ferr start usage
Diffstat (limited to 'pimd/pim_cmd.c')
-rw-r--r--pimd/pim_cmd.c39
1 files changed, 32 insertions, 7 deletions
diff --git a/pimd/pim_cmd.c b/pimd/pim_cmd.c
index 4a9c53cf29..4066614f4b 100644
--- a/pimd/pim_cmd.c
+++ b/pimd/pim_cmd.c
@@ -28,6 +28,7 @@
#include "hash.h"
#include "nexthop.h"
#include "vrf.h"
+#include "ferr.h"
#include "pimd.h"
#include "pim_mroute.h"
@@ -5839,13 +5840,8 @@ DEFUN (interface_ip_igmp_join,
return CMD_WARNING_CONFIG_FAILED;
}
- result = pim_if_igmp_join_add(ifp, group_addr, source_addr);
- if (result) {
- vty_out(vty,
- "%% Failure joining IGMP group %s source %s on interface %s: %d\n",
- group_str, source_str, ifp->name, result);
- return CMD_WARNING_CONFIG_FAILED;
- }
+ CMD_FERR_RETURN(pim_if_igmp_join_add(ifp, group_addr, source_addr),
+ "Failure joining IGMP group: $ERR");
return CMD_SUCCESS;
}
@@ -6959,6 +6955,31 @@ DEFUN (no_debug_pim_nht,
return CMD_SUCCESS;
}
+DEFUN (debug_pim_nht_rp,
+ debug_pim_nht_rp_cmd,
+ "debug pim nht rp",
+ DEBUG_STR
+ DEBUG_PIM_STR
+ "Nexthop Tracking\n"
+ "RP Nexthop Tracking\n")
+{
+ PIM_DO_DEBUG_PIM_NHT_RP;
+ return CMD_SUCCESS;
+}
+
+DEFUN (no_debug_pim_nht_rp,
+ no_debug_pim_nht_rp_cmd,
+ "no debug pim nht rp",
+ NO_STR
+ DEBUG_STR
+ DEBUG_PIM_STR
+ "Nexthop Tracking\n"
+ "RP Nexthop Tracking\n")
+{
+ PIM_DONT_DEBUG_PIM_NHT_RP;
+ return CMD_SUCCESS;
+}
+
DEFUN (debug_pim_events,
debug_pim_events_cmd,
"debug pim events",
@@ -8628,6 +8649,8 @@ void pim_cmd_init(void)
install_element(ENABLE_NODE, &no_debug_pim_cmd);
install_element(ENABLE_NODE, &debug_pim_nht_cmd);
install_element(ENABLE_NODE, &no_debug_pim_nht_cmd);
+ install_element(ENABLE_NODE, &debug_pim_nht_rp_cmd);
+ install_element(ENABLE_NODE, &no_debug_pim_nht_rp_cmd);
install_element(ENABLE_NODE, &debug_pim_events_cmd);
install_element(ENABLE_NODE, &no_debug_pim_events_cmd);
install_element(ENABLE_NODE, &debug_pim_packets_cmd);
@@ -8672,6 +8695,8 @@ void pim_cmd_init(void)
install_element(CONFIG_NODE, &no_debug_pim_cmd);
install_element(CONFIG_NODE, &debug_pim_nht_cmd);
install_element(CONFIG_NODE, &no_debug_pim_nht_cmd);
+ install_element(CONFIG_NODE, &debug_pim_nht_rp_cmd);
+ install_element(CONFIG_NODE, &no_debug_pim_nht_rp_cmd);
install_element(CONFIG_NODE, &debug_pim_events_cmd);
install_element(CONFIG_NODE, &no_debug_pim_events_cmd);
install_element(CONFIG_NODE, &debug_pim_packets_cmd);