December 2006
Intermediate to advanced
1188 pages
72h 8m
English
You want to change the Local Preference values to control which routes you use.
There are two ways to adjust Local Preference values on a router. The first method changes the Local Preference values for every route distributed into iBGP from this router:
Router1#configure terminalEnter configuration commands, one per line. End with CNTL/Z. Router1(config)#router bgpRouter1(config-router)#65500bgp default local-preferenceRouter1(config-router)#200exitRouter1(config)#endRouter1#
The second method uses route maps to give finer granularity control over which routes get what Local Preference values:
Router1#configure terminalEnter configuration commands, one per line. End with CNTL/Z. Router1(config)#ip prefix-listLOW_LP_PREFIXESseq10permitRouter1(config)#172.22.0.0/16route-mapLOCALPREFpermitRouter1(config-route-map)#10match ip address prefix-listRouter1(config-route-map)#LOW_LP_PREFIXESset local-preferenceRouter1(config-route-map)#50exitRouter1(config)#route-mapLOCALPREFpermitRouter1(config-route-map)#20exitRouter1(config)#router bgpRouter1(config-router)#65500neighbor192.168.1.5remote-asRouter1(config-router)#65510neighbor192.168.1.5route-mapLOCALPREFinRouter1(config-router)#exitRouter1(config)#endRouter1#
When BGP routers within an AS exchange information about a particular route using iBGP, they include the Local Preference value. All of the routers in the AS are then able to use this ...