]> git.proxmox.com Git - mirror_frr.git/commitdiff
pimd: cli changes for pim-debug-vxlan
authorAnuradha Karuppiah <anuradhak@cumulusnetworks.com>
Mon, 25 Mar 2019 00:34:45 +0000 (17:34 -0700)
committerAnuradha Karuppiah <anuradhak@cumulusnetworks.com>
Sat, 20 Apr 2019 15:33:23 +0000 (08:33 -0700)
Sample:
root@TORC12:~# vtysh -c "show run" |grep "debug pim vxlan"
debug pim vxlan
root@TORC12:~# vtysh -c "show debug" |grep "pim vxlan"
debug pim vxlan
root@TORC12:~#

Signed-off-by: Anuradha Karuppiah <anuradhak@cumulusnetworks.com>
pimd/pim_cmd.c
pimd/pim_cmd.h
pimd/pim_vty.c

index 4305cf78f2e56acedc6d0d32d3595866884a28d7..802c384ccb0d08b742f6faeab2f77ed07e6296dd 100644 (file)
@@ -7400,6 +7400,29 @@ DEFUN (no_debug_pim_zebra,
        return CMD_SUCCESS;
 }
 
+DEFUN (debug_pim_vxlan,
+       debug_pim_vxlan_cmd,
+       "debug pim vxlan",
+       DEBUG_STR
+       DEBUG_PIM_STR
+       DEBUG_PIM_VXLAN_STR)
+{
+       PIM_DO_DEBUG_VXLAN;
+       return CMD_SUCCESS;
+}
+
+DEFUN (no_debug_pim_vxlan,
+       no_debug_pim_vxlan_cmd,
+       "no debug pim vxlan",
+       NO_STR
+       DEBUG_STR
+       DEBUG_PIM_STR
+       DEBUG_PIM_VXLAN_STR)
+{
+       PIM_DONT_DEBUG_VXLAN;
+       return CMD_SUCCESS;
+}
+
 DEFUN (debug_msdp,
        debug_msdp_cmd,
        "debug msdp",
@@ -8900,6 +8923,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_vxlan_cmd);
+       install_element(ENABLE_NODE, &no_debug_pim_vxlan_cmd);
        install_element(ENABLE_NODE, &debug_msdp_cmd);
        install_element(ENABLE_NODE, &no_debug_msdp_cmd);
        install_element(ENABLE_NODE, &debug_msdp_events_cmd);
@@ -8941,6 +8966,8 @@ void pim_cmd_init(void)
        install_element(CONFIG_NODE, &no_debug_ssmpingd_cmd);
        install_element(CONFIG_NODE, &debug_pim_zebra_cmd);
        install_element(CONFIG_NODE, &no_debug_pim_zebra_cmd);
+       install_element(CONFIG_NODE, &debug_pim_vxlan_cmd);
+       install_element(CONFIG_NODE, &no_debug_pim_vxlan_cmd);
        install_element(CONFIG_NODE, &debug_msdp_cmd);
        install_element(CONFIG_NODE, &no_debug_msdp_cmd);
        install_element(CONFIG_NODE, &debug_msdp_events_cmd);
index b58da30bdd64847fb9d873d783d34c8e5db86da0..67d6e43c34a5a959958464034409f334b69388f6 100644 (file)
@@ -52,6 +52,7 @@
 #define DEBUG_PIM_PACKETDUMP_RECV_STR               "Dump received packets\n"
 #define DEBUG_PIM_TRACE_STR                         "PIM internal daemon activity\n"
 #define DEBUG_PIM_ZEBRA_STR                         "ZEBRA protocol activity\n"
+#define DEBUG_PIM_VXLAN_STR                         "PIM VxLAN events\n"
 #define DEBUG_SSMPINGD_STR                          "ssmpingd activity\n"
 #define CLEAR_IP_IGMP_STR                           "IGMP clear commands\n"
 #define CLEAR_IP_PIM_STR                            "PIM clear commands\n"
index 649578874842e9855b61906a35b36b38326167d3..9e677958d5b35f4c9f4a826ae8ccdd189fb19282 100644 (file)
@@ -119,6 +119,11 @@ int pim_debug_config_write(struct vty *vty)
                ++writes;
        }
 
+       if (PIM_DEBUG_VXLAN) {
+               vty_out(vty, "debug pim vxlan\n");
+               ++writes;
+       }
+
        if (PIM_DEBUG_SSMPINGD) {
                vty_out(vty, "debug ssmpingd\n");
                ++writes;