diff options
Diffstat (limited to 'pimd/pim_cmd.c')
| -rw-r--r-- | pimd/pim_cmd.c | 35 |
1 files changed, 25 insertions, 10 deletions
diff --git a/pimd/pim_cmd.c b/pimd/pim_cmd.c index 28b4af9457..ca86017f10 100644 --- a/pimd/pim_cmd.c +++ b/pimd/pim_cmd.c @@ -61,6 +61,7 @@ #include "pim_nht.h" #include "pim_bfd.h" #include "pim_vxlan.h" +#include "pim_mlag.h" #include "bfd.h" #include "pim_bsm.h" @@ -5996,12 +5997,6 @@ static int pim_rp_cmd_worker(struct pim_instance *pim, struct vty *vty, return CMD_WARNING_CONFIG_FAILED; } - if (result == PIM_GROUP_BAD_ADDR_MASK_COMBO) { - vty_out(vty, "%% Inconsistent address and mask: %s\n", - group); - return CMD_WARNING_CONFIG_FAILED; - } - return CMD_SUCCESS; } @@ -6347,6 +6342,7 @@ static int pim_ssm_cmd_worker(struct pim_instance *pim, struct vty *vty, const char *plist) { int result = pim_ssm_range_set(pim, pim->vrf_id, plist); + int ret = CMD_WARNING_CONFIG_FAILED; if (result == PIM_SSM_ERR_NONE) return CMD_SUCCESS; @@ -6357,12 +6353,13 @@ static int pim_ssm_cmd_worker(struct pim_instance *pim, struct vty *vty, break; case PIM_SSM_ERR_DUP: vty_out(vty, "%% duplicate config\n"); + ret = CMD_WARNING; break; default: vty_out(vty, "%% ssm range config failed\n"); } - return CMD_WARNING_CONFIG_FAILED; + return ret; } DEFUN (ip_pim_ssm_prefix_list, @@ -7385,12 +7382,14 @@ static int pim_cmd_interface_add(struct interface *ifp) struct pim_interface *pim_ifp = ifp->info; if (!pim_ifp) - (void)pim_if_new(ifp, false, true, false, false); + pim_ifp = pim_if_new(ifp, false, true, false, false); else PIM_IF_DO_PIM(pim_ifp->options); pim_if_addr_add_all(ifp); pim_if_membership_refresh(ifp); + + pim_if_create_pimreg(pim_ifp->pim); return 1; } @@ -7462,9 +7461,9 @@ DEFPY_HIDDEN (interface_ip_pim_activeactive, pim_ifp = ifp->info; if (no) - pim_ifp->activeactive = false; + pim_if_unconfigure_mlag_dualactive(pim_ifp); else - pim_ifp->activeactive = true; + pim_if_configure_mlag_dualactive(pim_ifp); return CMD_SUCCESS; } @@ -8382,6 +8381,20 @@ DEFUN (no_debug_pim_zebra, return CMD_SUCCESS; } +DEFUN(debug_pim_mlag, debug_pim_mlag_cmd, "debug pim mlag", + DEBUG_STR DEBUG_PIM_STR DEBUG_PIM_MLAG_STR) +{ + PIM_DO_DEBUG_MLAG; + return CMD_SUCCESS; +} + +DEFUN(no_debug_pim_mlag, no_debug_pim_mlag_cmd, "no debug pim mlag", + NO_STR DEBUG_STR DEBUG_PIM_STR DEBUG_PIM_MLAG_STR) +{ + PIM_DONT_DEBUG_MLAG; + return CMD_SUCCESS; +} + DEFUN (debug_pim_vxlan, debug_pim_vxlan_cmd, "debug pim vxlan", @@ -10408,6 +10421,8 @@ void pim_cmd_init(void) install_element(ENABLE_NODE, &no_debug_ssmpingd_cmd); install_element(ENABLE_NODE, &debug_pim_zebra_cmd); install_element(ENABLE_NODE, &no_debug_pim_zebra_cmd); + install_element(ENABLE_NODE, &debug_pim_mlag_cmd); + install_element(ENABLE_NODE, &no_debug_pim_mlag_cmd); install_element(ENABLE_NODE, &debug_pim_vxlan_cmd); install_element(ENABLE_NODE, &no_debug_pim_vxlan_cmd); install_element(ENABLE_NODE, &debug_msdp_cmd); |
