From 47e9b2923f633d4112315c29c2cedab7ff2ccb96 Mon Sep 17 00:00:00 2001 From: Daniel Walton Date: Fri, 13 Nov 2015 03:14:10 +0000 Subject: [PATCH] BGP: Remove deprecated commands and add warning that "show ipv6 bgp" will be deprecated in the future Signed-off-by: Daniel Walton Reviewed-by: Donald Sharp Reviewed-by: Vivek Venkatraman Ticket: CM-8144 --- bgpd/bgp_debug.c | 8 +- bgpd/bgp_route.c | 206 ++++++++------------------------------------ bgpd/bgp_routemap.c | 92 +++----------------- bgpd/bgp_vty.c | 72 ---------------- 4 files changed, 49 insertions(+), 329 deletions(-) diff --git a/bgpd/bgp_debug.c b/bgpd/bgp_debug.c index 3829a7d121..68106b449e 100644 --- a/bgpd/bgp_debug.c +++ b/bgpd/bgp_debug.c @@ -1732,7 +1732,7 @@ DEFUN (debug_bgp_normal, DEBUG_STR BGP_STR) { - vty_out (vty, "%% Ignoring old debugging command, please use the enhanced bgp debugs%s", + vty_out (vty, "%% This command will be deprecated in our next release, please use 'debug bgp neighbor-events'%s", VTY_NEWLINE); return CMD_SUCCESS; } @@ -1744,7 +1744,7 @@ DEFUN (debug_bgp_fsm, BGP_STR "deprecated BGP fsm command do not use") { - vty_out (vty, "%% Ignoring old debugging command, please use the enhanced bgp debugs%s", + vty_out (vty, "%% This command will be deprecated in our next release, please use 'debug bgp neighbor-events'%s", VTY_NEWLINE); return CMD_SUCCESS; } @@ -1756,7 +1756,7 @@ DEFUN (debug_bgp_events, BGP_STR "deprecated BGP events command do not use") { - vty_out (vty, "%% Ignoring old debugging command, please use the enhanced bgp debugs%s", + vty_out (vty, "%% This command will be deprecated in our next release, please use 'debug bgp neighbor-events'%s", VTY_NEWLINE); return CMD_SUCCESS; } @@ -1768,7 +1768,7 @@ DEFUN (debug_bgp_filter, BGP_STR "deprecated BGP filters command do not use") { - vty_out (vty, "%% Ignoring old debugging command, please use the enhanced bgp debugs%s", + vty_out (vty, "%% This command will be deprecated in our next release, please use 'debug bgp updates'%s", VTY_NEWLINE); return CMD_SUCCESS; } diff --git a/bgpd/bgp_route.c b/bgpd/bgp_route.c index 4d5d6ad690..cf88b3ee8a 100644 --- a/bgpd/bgp_route.c +++ b/bgpd/bgp_route.c @@ -4270,129 +4270,6 @@ ALIAS (no_ipv6_bgp_network, "IPv6 prefix /, e.g., 3ffe::/16\n") #endif /* HAVE_IPV6 */ -/* stubs for removed AS-Pathlimit commands, kept for config compatibility */ -ALIAS_DEPRECATED (bgp_network, - bgp_network_ttl_cmd, - "network A.B.C.D/M pathlimit <0-255>", - "Specify a network to announce via BGP\n" - "IP prefix /, e.g., 35.0.0.0/8\n" - "AS-Path hopcount limit attribute\n" - "AS-Pathlimit TTL, in number of AS-Path hops\n") -ALIAS_DEPRECATED (bgp_network_backdoor, - bgp_network_backdoor_ttl_cmd, - "network A.B.C.D/M backdoor pathlimit <0-255>", - "Specify a network to announce via BGP\n" - "IP prefix /, e.g., 35.0.0.0/8\n" - "Specify a BGP backdoor route\n" - "AS-Path hopcount limit attribute\n" - "AS-Pathlimit TTL, in number of AS-Path hops\n") -ALIAS_DEPRECATED (bgp_network_mask, - bgp_network_mask_ttl_cmd, - "network A.B.C.D mask A.B.C.D pathlimit <0-255>", - "Specify a network to announce via BGP\n" - "Network number\n" - "Network mask\n" - "Network mask\n" - "AS-Path hopcount limit attribute\n" - "AS-Pathlimit TTL, in number of AS-Path hops\n") -ALIAS_DEPRECATED (bgp_network_mask_backdoor, - bgp_network_mask_backdoor_ttl_cmd, - "network A.B.C.D mask A.B.C.D backdoor pathlimit <0-255>", - "Specify a network to announce via BGP\n" - "Network number\n" - "Network mask\n" - "Network mask\n" - "Specify a BGP backdoor route\n" - "AS-Path hopcount limit attribute\n" - "AS-Pathlimit TTL, in number of AS-Path hops\n") -ALIAS_DEPRECATED (bgp_network_mask_natural, - bgp_network_mask_natural_ttl_cmd, - "network A.B.C.D pathlimit <0-255>", - "Specify a network to announce via BGP\n" - "Network number\n" - "AS-Path hopcount limit attribute\n" - "AS-Pathlimit TTL, in number of AS-Path hops\n") -ALIAS_DEPRECATED (bgp_network_mask_natural_backdoor, - bgp_network_mask_natural_backdoor_ttl_cmd, - "network A.B.C.D backdoor pathlimit <1-255>", - "Specify a network to announce via BGP\n" - "Network number\n" - "Specify a BGP backdoor route\n" - "AS-Path hopcount limit attribute\n" - "AS-Pathlimit TTL, in number of AS-Path hops\n") -ALIAS_DEPRECATED (no_bgp_network, - no_bgp_network_ttl_cmd, - "no network A.B.C.D/M pathlimit <0-255>", - NO_STR - "Specify a network to announce via BGP\n" - "IP prefix /, e.g., 35.0.0.0/8\n" - "AS-Path hopcount limit attribute\n" - "AS-Pathlimit TTL, in number of AS-Path hops\n") -ALIAS_DEPRECATED (no_bgp_network, - no_bgp_network_backdoor_ttl_cmd, - "no network A.B.C.D/M backdoor pathlimit <0-255>", - NO_STR - "Specify a network to announce via BGP\n" - "IP prefix /, e.g., 35.0.0.0/8\n" - "Specify a BGP backdoor route\n" - "AS-Path hopcount limit attribute\n" - "AS-Pathlimit TTL, in number of AS-Path hops\n") -ALIAS_DEPRECATED (no_bgp_network, - no_bgp_network_mask_ttl_cmd, - "no network A.B.C.D mask A.B.C.D pathlimit <0-255>", - NO_STR - "Specify a network to announce via BGP\n" - "Network number\n" - "Network mask\n" - "Network mask\n" - "AS-Path hopcount limit attribute\n" - "AS-Pathlimit TTL, in number of AS-Path hops\n") -ALIAS_DEPRECATED (no_bgp_network_mask, - no_bgp_network_mask_backdoor_ttl_cmd, - "no network A.B.C.D mask A.B.C.D backdoor pathlimit <0-255>", - NO_STR - "Specify a network to announce via BGP\n" - "Network number\n" - "Network mask\n" - "Network mask\n" - "Specify a BGP backdoor route\n" - "AS-Path hopcount limit attribute\n" - "AS-Pathlimit TTL, in number of AS-Path hops\n") -ALIAS_DEPRECATED (no_bgp_network_mask_natural, - no_bgp_network_mask_natural_ttl_cmd, - "no network A.B.C.D pathlimit <0-255>", - NO_STR - "Specify a network to announce via BGP\n" - "Network number\n" - "AS-Path hopcount limit attribute\n" - "AS-Pathlimit TTL, in number of AS-Path hops\n") -ALIAS_DEPRECATED (no_bgp_network_mask_natural, - no_bgp_network_mask_natural_backdoor_ttl_cmd, - "no network A.B.C.D backdoor pathlimit <0-255>", - NO_STR - "Specify a network to announce via BGP\n" - "Network number\n" - "Specify a BGP backdoor route\n" - "AS-Path hopcount limit attribute\n" - "AS-Pathlimit TTL, in number of AS-Path hops\n") -#ifdef HAVE_IPV6 -ALIAS_DEPRECATED (ipv6_bgp_network, - ipv6_bgp_network_ttl_cmd, - "network X:X::X:X/M pathlimit <0-255>", - "Specify a network to announce via BGP\n" - "IPv6 prefix /\n" - "AS-Path hopcount limit attribute\n" - "AS-Pathlimit TTL, in number of AS-Path hops\n") -ALIAS_DEPRECATED (no_ipv6_bgp_network, - no_ipv6_bgp_network_ttl_cmd, - "no network X:X::X:X/M pathlimit <0-255>", - NO_STR - "Specify a network to announce via BGP\n" - "IPv6 prefix /\n" - "AS-Path hopcount limit attribute\n" - "AS-Pathlimit TTL, in number of AS-Path hops\n") -#endif /* HAVE_IPV6 */ - /* Aggreagete address: advertise-map Set condition to advertise attribute @@ -7995,6 +7872,14 @@ DEFUN (show_bgp_ipv6_safi, return bgp_show (vty, NULL, AFI_IP6, SAFI_UNICAST, bgp_show_type_normal, NULL, use_json); } +static void +bgp_show_ipv6_bgp_deprecate_warning (struct vty *vty) +{ + vty_out (vty, "WARNING: The 'show ipv6 bgp' parse tree will be deprecated in our" + " next release%sPlese use 'show bgp ipv6' instead%s%s", + VTY_NEWLINE, VTY_NEWLINE, VTY_NEWLINE); +} + /* old command */ DEFUN (show_ipv6_bgp, show_ipv6_bgp_cmd, @@ -8005,6 +7890,7 @@ DEFUN (show_ipv6_bgp, "JavaScript Object Notation\n") { u_char use_json = (argv[0] != NULL); + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show (vty, NULL, AFI_IP6, SAFI_UNICAST, bgp_show_type_normal, NULL, use_json); } @@ -8113,6 +7999,7 @@ DEFUN (show_ipv6_bgp_route, "JavaScript Object Notation\n") { u_char use_json = (argv[1] != NULL); + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_route (vty, NULL, argv[0], AFI_IP6, SAFI_UNICAST, NULL, 0, BGP_PATH_ALL, use_json); } @@ -8220,6 +8107,7 @@ DEFUN (show_ipv6_bgp_prefix, "JavaScript Object Notation\n") { u_char use_json = (argv[1] != NULL); + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_route (vty, NULL, argv[0], AFI_IP6, SAFI_UNICAST, NULL, 1, BGP_PATH_ALL, use_json); } @@ -8316,6 +8204,7 @@ DEFUN (show_ipv6_mbgp, "JavaScript Object Notation\n") { u_char use_json = (argv[0] != NULL); + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show (vty, NULL, AFI_IP6, SAFI_MULTICAST, bgp_show_type_normal, NULL, use_json); } @@ -8331,6 +8220,7 @@ DEFUN (show_ipv6_mbgp_route, "JavaScript Object Notation\n") { u_char use_json = (argv[1] != NULL); + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_route (vty, NULL, argv[0], AFI_IP6, SAFI_MULTICAST, NULL, 0, BGP_PATH_ALL, use_json); } @@ -8345,6 +8235,7 @@ DEFUN (show_ipv6_mbgp_prefix, "JavaScript Object Notation\n") { u_char use_json = (argv[1] != NULL); + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_route (vty, NULL, argv[0], AFI_IP6, SAFI_MULTICAST, NULL, 1, BGP_PATH_ALL, use_json); } #endif @@ -8474,6 +8365,7 @@ DEFUN (show_ipv6_bgp_regexp, "Display routes matching the AS path regular expression\n" "A regular-expression to match the BGP AS paths\n") { + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_regexp (vty, argc, argv, AFI_IP6, SAFI_UNICAST, bgp_show_type_regexp); } @@ -8488,6 +8380,7 @@ DEFUN (show_ipv6_mbgp_regexp, "Display routes matching the AS path regular expression\n" "A regular-expression to match the MBGP AS paths\n") { + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_regexp (vty, argc, argv, AFI_IP6, SAFI_MULTICAST, bgp_show_type_regexp); } @@ -8589,6 +8482,7 @@ DEFUN (show_ipv6_bgp_prefix_list, "Display routes matching the prefix-list\n" "IPv6 prefix-list name\n") { + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_prefix_list (vty, argv[0], AFI_IP6, SAFI_UNICAST, bgp_show_type_prefix_list); } @@ -8603,6 +8497,7 @@ DEFUN (show_ipv6_mbgp_prefix_list, "Display routes matching the prefix-list\n" "IPv6 prefix-list name\n") { + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_prefix_list (vty, argv[0], AFI_IP6, SAFI_MULTICAST, bgp_show_type_prefix_list); } @@ -8703,6 +8598,7 @@ DEFUN (show_ipv6_bgp_filter_list, "Display routes conforming to the filter-list\n" "Regular expression access list name\n") { + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_filter_list (vty, argv[0], AFI_IP6, SAFI_UNICAST, bgp_show_type_filter_list); } @@ -8717,6 +8613,7 @@ DEFUN (show_ipv6_mbgp_filter_list, "Display routes conforming to the filter-list\n" "Regular expression access list name\n") { + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_filter_list (vty, argv[0], AFI_IP6, SAFI_MULTICAST, bgp_show_type_filter_list); } @@ -8911,6 +8808,7 @@ DEFUN (show_ipv6_bgp_community_all, BGP_STR "Display routes matching the communities\n") { + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show (vty, NULL, AFI_IP6, SAFI_UNICAST, bgp_show_type_community_all, NULL, 0); } @@ -8924,6 +8822,7 @@ DEFUN (show_ipv6_mbgp_community_all, MBGP_STR "Display routes matching the communities\n") { + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show (vty, NULL, AFI_IP6, SAFI_MULTICAST, bgp_show_type_community_all, NULL, 0); } @@ -9658,6 +9557,7 @@ DEFUN (show_ipv6_bgp_community, "Do not advertise to any peer (well-known community)\n" "Do not export to next AS (well-known community)\n") { + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_community (vty, NULL, argc, argv, 0, AFI_IP6, SAFI_UNICAST); } @@ -9889,6 +9789,7 @@ DEFUN (show_ipv6_bgp_community_exact, "Do not export to next AS (well-known community)\n" "Exact match of the communities") { + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_community (vty, NULL, argc, argv, 1, AFI_IP6, SAFI_UNICAST); } @@ -9971,6 +9872,7 @@ DEFUN (show_ipv6_mbgp_community, "Do not advertise to any peer (well-known community)\n" "Do not export to next AS (well-known community)\n") { + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_community (vty, NULL, argc, argv, 0, AFI_IP6, SAFI_MULTICAST); } @@ -10051,6 +9953,7 @@ DEFUN (show_ipv6_mbgp_community_exact, "Do not export to next AS (well-known community)\n" "Exact match of the communities") { + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_community (vty, NULL, argc, argv, 1, AFI_IP6, SAFI_MULTICAST); } @@ -10239,6 +10142,7 @@ DEFUN (show_ipv6_bgp_community_list, "Display routes matching the community-list\n" "community-list name\n") { + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_community_list (vty, argv[0], 0, AFI_IP6, SAFI_UNICAST); } @@ -10252,6 +10156,7 @@ DEFUN (show_ipv6_mbgp_community_list, "Display routes matching the community-list\n" "community-list name\n") { + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_community_list (vty, argv[0], 0, AFI_IP6, SAFI_MULTICAST); } @@ -10290,6 +10195,7 @@ DEFUN (show_ipv6_bgp_community_list_exact, "community-list name\n" "Exact match of the communities\n") { + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_community_list (vty, argv[0], 1, AFI_IP6, SAFI_UNICAST); } @@ -10304,6 +10210,7 @@ DEFUN (show_ipv6_mbgp_community_list_exact, "community-list name\n" "Exact match of the communities\n") { + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_community_list (vty, argv[0], 1, AFI_IP6, SAFI_MULTICAST); } #endif /* HAVE_IPV6 */ @@ -10433,6 +10340,7 @@ DEFUN (show_ipv6_bgp_prefix_longer, "IPv6 prefix /, e.g., 3ffe::/16\n" "Display route and more specific routes\n") { + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_prefix_longer (vty, argv[0], AFI_IP6, SAFI_UNICAST, bgp_show_type_prefix_longer); } @@ -10447,6 +10355,7 @@ DEFUN (show_ipv6_mbgp_prefix_longer, "IPv6 prefix /, e.g., 3ffe::/16\n" "Display route and more specific routes\n") { + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_prefix_longer (vty, argv[0], AFI_IP6, SAFI_MULTICAST, bgp_show_type_prefix_longer); } @@ -11719,6 +11628,7 @@ DEFUN (ipv6_mbgp_neighbor_advertised_route, if (! peer) return CMD_WARNING; + bgp_show_ipv6_bgp_deprecate_warning(vty); return peer_adj_routes (vty, peer, AFI_IP6, SAFI_MULTICAST, 0, NULL, use_json); } #endif /* HAVE_IPV6 */ @@ -12358,6 +12268,7 @@ DEFUN (ipv6_mbgp_neighbor_received_routes, if (! peer) return CMD_WARNING; + bgp_show_ipv6_bgp_deprecate_warning(vty); return peer_adj_routes (vty, peer, AFI_IP6, SAFI_MULTICAST, 1, NULL,use_json); } @@ -12838,6 +12749,7 @@ DEFUN (ipv6_mbgp_neighbor_routes, if (! peer) return CMD_WARNING; + bgp_show_ipv6_bgp_deprecate_warning(vty); return bgp_show_neighbor_route (vty, peer, AFI_IP6, SAFI_MULTICAST, bgp_show_type_neighbor, use_json); } @@ -14284,54 +14196,6 @@ bgp_route_init (void) install_element (BGP_IPV4_NODE, &bgp_damp_set3_cmd); install_element (BGP_IPV4_NODE, &bgp_damp_unset_cmd); install_element (BGP_IPV4_NODE, &bgp_damp_unset2_cmd); - - /* Deprecated AS-Pathlimit commands */ - install_element (BGP_NODE, &bgp_network_ttl_cmd); - install_element (BGP_NODE, &bgp_network_mask_ttl_cmd); - install_element (BGP_NODE, &bgp_network_mask_natural_ttl_cmd); - install_element (BGP_NODE, &bgp_network_backdoor_ttl_cmd); - install_element (BGP_NODE, &bgp_network_mask_backdoor_ttl_cmd); - install_element (BGP_NODE, &bgp_network_mask_natural_backdoor_ttl_cmd); - - install_element (BGP_NODE, &no_bgp_network_ttl_cmd); - install_element (BGP_NODE, &no_bgp_network_mask_ttl_cmd); - install_element (BGP_NODE, &no_bgp_network_mask_natural_ttl_cmd); - install_element (BGP_NODE, &no_bgp_network_backdoor_ttl_cmd); - install_element (BGP_NODE, &no_bgp_network_mask_backdoor_ttl_cmd); - install_element (BGP_NODE, &no_bgp_network_mask_natural_backdoor_ttl_cmd); - - install_element (BGP_IPV4_NODE, &bgp_network_ttl_cmd); - install_element (BGP_IPV4_NODE, &bgp_network_mask_ttl_cmd); - install_element (BGP_IPV4_NODE, &bgp_network_mask_natural_ttl_cmd); - install_element (BGP_IPV4_NODE, &bgp_network_backdoor_ttl_cmd); - install_element (BGP_IPV4_NODE, &bgp_network_mask_backdoor_ttl_cmd); - install_element (BGP_IPV4_NODE, &bgp_network_mask_natural_backdoor_ttl_cmd); - - install_element (BGP_IPV4_NODE, &no_bgp_network_ttl_cmd); - install_element (BGP_IPV4_NODE, &no_bgp_network_mask_ttl_cmd); - install_element (BGP_IPV4_NODE, &no_bgp_network_mask_natural_ttl_cmd); - install_element (BGP_IPV4_NODE, &no_bgp_network_backdoor_ttl_cmd); - install_element (BGP_IPV4_NODE, &no_bgp_network_mask_backdoor_ttl_cmd); - install_element (BGP_IPV4_NODE, &no_bgp_network_mask_natural_backdoor_ttl_cmd); - - install_element (BGP_IPV4M_NODE, &bgp_network_ttl_cmd); - install_element (BGP_IPV4M_NODE, &bgp_network_mask_ttl_cmd); - install_element (BGP_IPV4M_NODE, &bgp_network_mask_natural_ttl_cmd); - install_element (BGP_IPV4M_NODE, &bgp_network_backdoor_ttl_cmd); - install_element (BGP_IPV4M_NODE, &bgp_network_mask_backdoor_ttl_cmd); - install_element (BGP_IPV4M_NODE, &bgp_network_mask_natural_backdoor_ttl_cmd); - - install_element (BGP_IPV4M_NODE, &no_bgp_network_ttl_cmd); - install_element (BGP_IPV4M_NODE, &no_bgp_network_mask_ttl_cmd); - install_element (BGP_IPV4M_NODE, &no_bgp_network_mask_natural_ttl_cmd); - install_element (BGP_IPV4M_NODE, &no_bgp_network_backdoor_ttl_cmd); - install_element (BGP_IPV4M_NODE, &no_bgp_network_mask_backdoor_ttl_cmd); - install_element (BGP_IPV4M_NODE, &no_bgp_network_mask_natural_backdoor_ttl_cmd); - -#ifdef HAVE_IPV6 - install_element (BGP_IPV6_NODE, &ipv6_bgp_network_ttl_cmd); - install_element (BGP_IPV6_NODE, &no_ipv6_bgp_network_ttl_cmd); -#endif } void diff --git a/bgpd/bgp_routemap.c b/bgpd/bgp_routemap.c index d402e60ab6..38e5bd7296 100644 --- a/bgpd/bgp_routemap.c +++ b/bgpd/bgp_routemap.c @@ -3679,19 +3679,6 @@ DEFUN (set_ip_nexthop_unchanged, return bgp_route_set_add (vty, vty->index, "ip next-hop", "unchanged"); } -DEFUN_DEPRECATED (no_set_ip_nexthop_peer, - no_set_ip_nexthop_peer_cmd, - "no set ip next-hop peer-address", - NO_STR - SET_STR - IP_STR - "Next hop address\n" - "Use peer address (for BGP only)\n") -{ - return bgp_route_set_delete (vty, vty->index, "ip next-hop", NULL); -} - - DEFUN (no_set_ip_nexthop, no_set_ip_nexthop_cmd, "no set ip next-hop", @@ -3714,6 +3701,15 @@ ALIAS (no_set_ip_nexthop, "Next hop address\n" "IP address of next hop\n") +ALIAS (no_set_ip_nexthop, + no_set_ip_nexthop_peer_cmd, + "no set ip next-hop peer-address", + NO_STR + SET_STR + IP_STR + "Next hop address\n" + "Use peer address (for BGP only)\n") + DEFUN (set_metric, set_metric_cmd, "set metric <0-4294967295>", @@ -4594,65 +4590,6 @@ ALIAS (no_set_originator_id, "BGP originator ID attribute\n" "IP address of originator\n") -DEFUN_DEPRECATED (set_pathlimit_ttl, - set_pathlimit_ttl_cmd, - "set pathlimit ttl <1-255>", - SET_STR - "BGP AS-Pathlimit attribute\n" - "Set AS-Path Hop-count TTL\n") -{ - return CMD_SUCCESS; -} - -DEFUN_DEPRECATED (no_set_pathlimit_ttl, - no_set_pathlimit_ttl_cmd, - "no set pathlimit ttl", - NO_STR - SET_STR - "BGP AS-Pathlimit attribute\n" - "Set AS-Path Hop-count TTL\n") -{ - return CMD_SUCCESS; -} - -ALIAS (no_set_pathlimit_ttl, - no_set_pathlimit_ttl_val_cmd, - "no set pathlimit ttl <1-255>", - NO_STR - MATCH_STR - "BGP AS-Pathlimit attribute\n" - "Set AS-Path Hop-count TTL\n") - -DEFUN_DEPRECATED (match_pathlimit_as, - match_pathlimit_as_cmd, - "match pathlimit as <1-65535>", - MATCH_STR - "BGP AS-Pathlimit attribute\n" - "Match Pathlimit AS number\n") -{ - return CMD_SUCCESS; -} - -DEFUN_DEPRECATED (no_match_pathlimit_as, - no_match_pathlimit_as_cmd, - "no match pathlimit as", - NO_STR - MATCH_STR - "BGP AS-Pathlimit attribute\n" - "Match Pathlimit AS number\n") -{ - return CMD_SUCCESS; -} - -ALIAS (no_match_pathlimit_as, - no_match_pathlimit_as_val_cmd, - "no match pathlimit as <1-65535>", - NO_STR - MATCH_STR - "BGP AS-Pathlimit attribute\n" - "Match Pathlimit ASN\n") - - /* Initialization of route map. */ void bgp_route_map_init (void) @@ -4757,6 +4694,7 @@ bgp_route_map_init (void) install_element (RMAP_NODE, &set_ip_nexthop_unchanged_cmd); install_element (RMAP_NODE, &no_set_ip_nexthop_cmd); install_element (RMAP_NODE, &no_set_ip_nexthop_val_cmd); + install_element (RMAP_NODE, &no_set_ip_nexthop_peer_cmd); install_element (RMAP_NODE, &set_local_pref_cmd); install_element (RMAP_NODE, &no_set_local_pref_cmd); install_element (RMAP_NODE, &no_set_local_pref_val_cmd); @@ -4828,16 +4766,6 @@ bgp_route_map_init (void) install_element (RMAP_NODE, &set_ipv6_nexthop_peer_cmd); install_element (RMAP_NODE, &no_set_ipv6_nexthop_peer_cmd); #endif /* HAVE_IPV6 */ - - /* AS-Pathlimit: functionality removed, commands kept for - * compatibility. - */ - install_element (RMAP_NODE, &set_pathlimit_ttl_cmd); - install_element (RMAP_NODE, &no_set_pathlimit_ttl_cmd); - install_element (RMAP_NODE, &no_set_pathlimit_ttl_val_cmd); - install_element (RMAP_NODE, &match_pathlimit_as_cmd); - install_element (RMAP_NODE, &no_match_pathlimit_as_cmd); - install_element (RMAP_NODE, &no_match_pathlimit_as_val_cmd); } void diff --git a/bgpd/bgp_vty.c b/bgpd/bgp_vty.c index 911cc5953b..fd096eff22 100644 --- a/bgpd/bgp_vty.c +++ b/bgpd/bgp_vty.c @@ -597,17 +597,6 @@ DEFUN (no_auto_summary, return CMD_SUCCESS; } -DEFUN_DEPRECATED (neighbor_version, - neighbor_version_cmd, - NEIGHBOR_CMD "version (4|4-)", - NEIGHBOR_STR - NEIGHBOR_ADDR_STR - "Set the BGP version to match a neighbor\n" - "Neighbor's BGP version\n") -{ - return CMD_SUCCESS; -} - /* "router bgp" commands. */ DEFUN (router_bgp, router_bgp_cmd, @@ -3255,30 +3244,6 @@ DEFUN (no_neighbor_shutdown, return peer_flag_unset_vty (vty, argv[0], PEER_FLAG_SHUTDOWN); } -/* Deprecated neighbor capability route-refresh. */ -DEFUN_DEPRECATED (neighbor_capability_route_refresh, - neighbor_capability_route_refresh_cmd, - NEIGHBOR_CMD2 "capability route-refresh", - NEIGHBOR_STR - NEIGHBOR_ADDR_STR2 - "Advertise capability to the peer\n" - "Advertise route-refresh capability to this neighbor\n") -{ - return CMD_SUCCESS; -} - -DEFUN_DEPRECATED (no_neighbor_capability_route_refresh, - no_neighbor_capability_route_refresh_cmd, - NO_NEIGHBOR_CMD2 "capability route-refresh", - NO_STR - NEIGHBOR_STR - NEIGHBOR_ADDR_STR2 - "Advertise capability to the peer\n" - "Advertise route-refresh capability to this neighbor\n") -{ - return CMD_SUCCESS; -} - /* neighbor capability dynamic. */ DEFUN (neighbor_capability_dynamic, neighbor_capability_dynamic_cmd, @@ -4155,31 +4120,6 @@ ALIAS (no_neighbor_attr_unchanged, "As-path attribute\n" "Nexthop attribute\n") -/* For old version Zebra compatibility. */ -DEFUN_DEPRECATED (neighbor_transparent_as, - neighbor_transparent_as_cmd, - NEIGHBOR_CMD "transparent-as", - NEIGHBOR_STR - NEIGHBOR_ADDR_STR - "Do not append my AS number even peer is EBGP peer\n") -{ - return peer_af_flag_set_vty (vty, argv[0], bgp_node_afi (vty), - bgp_node_safi (vty), - PEER_FLAG_AS_PATH_UNCHANGED); -} - -DEFUN_DEPRECATED (neighbor_transparent_nexthop, - neighbor_transparent_nexthop_cmd, - NEIGHBOR_CMD "transparent-nexthop", - NEIGHBOR_STR - NEIGHBOR_ADDR_STR - "Do not change nexthop even peer is EBGP peer\n") -{ - return peer_af_flag_set_vty (vty, argv[0], bgp_node_afi (vty), - bgp_node_safi (vty), - PEER_FLAG_NEXTHOP_UNCHANGED); -} - /* EBGP multihop configuration. */ static int peer_ebgp_multihop_set_vty (struct vty *vty, const char *ip_str, @@ -12394,11 +12334,6 @@ bgp_vty_init (void) install_element (BGP_IPV6_NODE, &neighbor_nexthop_local_unchanged_cmd); install_element (BGP_IPV6_NODE, &no_neighbor_nexthop_local_unchanged_cmd); - /* "transparent-as" and "transparent-nexthop" for old version - compatibility. */ - install_element (BGP_NODE, &neighbor_transparent_as_cmd); - install_element (BGP_NODE, &neighbor_transparent_nexthop_cmd); - /* "neighbor next-hop-self" commands. */ install_element (BGP_NODE, &neighbor_nexthop_self_cmd); install_element (BGP_NODE, &no_neighbor_nexthop_self_cmd); @@ -12582,10 +12517,6 @@ bgp_vty_init (void) install_element (BGP_NODE, &neighbor_shutdown_cmd); install_element (BGP_NODE, &no_neighbor_shutdown_cmd); - /* Deprecated "neighbor capability route-refresh" commands.*/ - install_element (BGP_NODE, &neighbor_capability_route_refresh_cmd); - install_element (BGP_NODE, &no_neighbor_capability_route_refresh_cmd); - /* "neighbor capability extended-nexthop" commands.*/ install_element (BGP_NODE, &neighbor_capability_enhe_cmd); install_element (BGP_NODE, &no_neighbor_capability_enhe_cmd); @@ -12685,9 +12616,6 @@ bgp_vty_init (void) install_element (BGP_NODE, &no_neighbor_advertise_interval_cmd); install_element (BGP_NODE, &no_neighbor_advertise_interval_val_cmd); - /* "neighbor version" commands. */ - install_element (BGP_NODE, &neighbor_version_cmd); - /* "neighbor interface" commands. */ install_element (BGP_NODE, &neighbor_interface_cmd); install_element (BGP_NODE, &no_neighbor_interface_cmd); -- 2.39.5