[quagga-dev 12142] Re: [PATCH 3/4] bgpd: Addition of show ip bgp dampening tree

David Lamparter equinox at opensourcerouting.org
Tue Apr 14 11:30:11 BST 2015


On Mon, Mar 16, 2015 at 11:25:28PM +0530, Balaji.G wrote:
> Patch contains

NAK (2/4 and 3/4) - Can you please combine 2/4 + 3/4 into one patch, and
address the comments below:

> +++ b/bgpd/bgp_route.c
> @@ -6380,6 +6380,8 @@ bgp_show_table (struct vty *vty, struct bgp_table *table, struct in_addr *router
>    return CMD_SUCCESS;
>  }
>  
> +
> +

Remove this whitespace change

> @@ -6396,6 +6398,12 @@ bgp_show (struct vty *vty, struct bgp *bgp, afi_t afi, safi_t safi,
>  
> +  if (!CHECK_FLAG (bgp->af_flags[afi][safi], BGP_CONFIG_DAMPENING))
> +    {
> +      vty_out (vty, "dampening not enabled for %s%s",
> +                   afi == AFI_IP ? "IPv4" : "IPv6", VTY_NEWLINE);
> +      return CMD_WARNING;
> +    }

This looks incorrect/why is this here?

> @@ -7154,6 +7162,7 @@ DEFUN (show_ip_bgp_regexp,
>  			  bgp_show_type_regexp);
>  }
>  
> +

remove this whitespace change

>  
> +ALIAS (show_ip_bgp_flap_regexp, 
> +       show_ip_bgp_damp_flap_regexp_cmd,

(...)

>         BGP_STR
> -       "Display flap statistics of routes\n")
> +       "Display flap-statistics of routes\n")

It's "flap statistics" everywhere... don't add the "-"


>    install_element (VIEW_NODE, &show_ip_bgp_neighbor_received_prefix_filter_cmd);
>    install_element (VIEW_NODE, &show_ip_bgp_ipv4_neighbor_received_prefix_filter_cmd);
>    install_element (VIEW_NODE, &show_ip_bgp_dampened_paths_cmd);
> -  install_element (VIEW_NODE, &show_ip_bgp_flap_statistics_cmd);
> +  install_element (ENABLE_NODE, &show_ip_bgp_flap_statistics_cmd);

Why is this moved to ENABLE_NODE?

> +  install_element (VIEW_NODE, &show_ip_bgp_dampening_info_cmd);

All ALIAS() commands need install_element() too.

>    install_element (VIEW_NODE, &show_ip_bgp_flap_address_cmd);
>    install_element (VIEW_NODE, &show_ip_bgp_flap_prefix_cmd);
>    install_element (VIEW_NODE, &show_ip_bgp_flap_cidr_only_cmd);
> @@ -12719,6 +12819,7 @@ bgp_route_init (void)
>    install_element (ENABLE_NODE, &show_ip_bgp_ipv4_neighbor_received_prefix_filter_cmd);
>    install_element (ENABLE_NODE, &show_ip_bgp_dampened_paths_cmd);
>    install_element (ENABLE_NODE, &show_ip_bgp_flap_statistics_cmd);
> +  install_element (ENABLE_NODE, &show_ip_bgp_dampening_info_cmd);
>    install_element (ENABLE_NODE, &show_ip_bgp_flap_address_cmd);
>    install_element (ENABLE_NODE, &show_ip_bgp_flap_prefix_cmd);
>    install_element (ENABLE_NODE, &show_ip_bgp_flap_cidr_only_cmd);





More information about the Quagga-dev mailing list