Chapter 29
| IP Routing Commands
Policy-based Routing for BGP
– 1008 –
set local-preference This command sets the priority within the local AS for a routing message. Use the
no form to remove this entry from a route map.
Syntax
set local-preference preference
no set local-preference
preference – Degree of preference iBGP peers give local routes during BGP
best path selection. The higher the value, the more the route is to be
preferred. (Range: 1-4294967295)
Command Mode
Route Map
Command Usage
â—† The preference is sent only to routers in the local autonomous system. To
specify the metric for inter-autonomous systems, use the set metric command.
â—† A route with a higher local priority level when compared with other routes to
the same destination will be preferred over other routes.
Example
Console(config)#route-map RD permit 15
Console(config-route-map)#match peer 192.168.0.99
Console(config-route-map)#set local-preference 2
Console(config-route-map)#
set metric This command sets the metric value of a route to external neighbors. Use the no
form to restore the default value.
Syntax
set metric [+ | -]metric-value
no set metric
metric-value – Metric value assigned to all external routes for the
specified protocol. (Range: 0-4294967295)
Default Setting
The dynamically learned metric value.
Command Mode
Route Map
Command Usage
â—† Lower metric values indicate a higher priority.