nexthop route-map

To specify that Border Gateway Protocol (BGP) routes are resolved using only the next hops that have routes that match specific characteristics, use the nexthop route-map command. To remove the route map, use the no form of this command.

nexthop route-map name

no nexthop route-map name

Syntax Description

Route map name. The name can be any alphanumeric string up to 63 characters.

Command Default


Command Modes

Address-family configuration mode

Command History

This command was introduced.

Usage Guidelines

Use this command to configure route policy filtering for next hops.

BGP next-hop filtering allows you to specify that when a next-hop address is checked with the Routing Information Base (RIB), the underlying route for that next-hop address is passed through the route map. If the route map rejects the route, the next-hop address is treated as unreachable.

BGP marks all next hops that are rejected by the route policy as invalid and does not calculate the best path for the routes that use the invalid next-hop address.

This command requires an LAN Enterprise Services license.


This example shows how to configure a route map to filter the next-hop address:

switch# configure terminal
switch(config)#route-map CHECK-BGP25 deny 10
switch(config-route-map)# match ip address prefix-list FILTER25
switch(config-route-map)# match source-protocol ospf-o1
switch(config-route-map)# exit
switch(config)#ip prefix-list FILTER25 seq 5 permit le 25
switch(config)# router bgp 1.0
switch(config-router)# address-family ipv4 unicast
switch(config-router-af)# nexthop route-map CHECK-BGP25

Related Commands

feature bgp
Enables BGP.
nexthop trigger-delay
Configures the delay timers for BGP next-hop address tracking.
Defines the conditions for redistributing routes from one routing protocol into another.