Cisco Router Challenge 83
Outline
This challenge involves the configuration of BGP for a default
local-preference.The objectives of this challenge are
to:
Commands
# config
t
(config)#
router bgp 172
(config-router)# neighbor 11.11.11.11
remote-as 300
(config-router)# neighbor 12.12.12.12
remote-as 311
(config-router)# network 160.0.0.0
(config-router)# bgp
default local-preference 100
Example
# config
t
(config)#
router bgp 172
(config-router)# neighbor 11.11.11.11
remote-as 300
(config-router)# neighbor 12.12.12.12
remote-as 311
(config-router)# network 160.0.0.0
(config-router)# bgp ?
always-compare-med Allow comparing MED from different
neighbors
bestpath Change the default bestpath selection
client-to-client Configure client to client route
reflection
cluster-id Configure Route-Reflector
Cluster-id
confederation AS confederation parameters
dampening Enable route-flap dampening
default Configure BGP defaults
deterministic-med Pick the best-MED path among paths
advertised from
the
neighboring AS
fast-external-fallover Immediately reset session if a link to
a directly
connected
external peer goes down
log-neighbor-changes Log neighbor up/down and reset reason
redistribute-internal Allow redistribution of iBGP
into IGPs (dangerous)
router-id Override configured router
identifier
scan-time Configure background scanner
interval
(config-router)# bgp def ?
ipv4-unicast Activate ipv4-unicast for a peer by
default
local-preference local preference (higher=more
preferred)
(config-router)# bgp
def l ?
<0-4294967295> Configure default local preference
value
(config-router)# bgp
default local-preference 100
Explanation
The local preference attribute in BGP is used to give a degree of
preference to routes when comparing them with other routes. Thus:
(config-router)#
bgp default local-preference
100
has a higher precedance than the following:
# config t
(config)# router bgp 172
(config-router)#
neighbor 1.1.1.1 remote-as 200
(config-router)#
neighbor 12.12.12.12 remote-as 311
(config-router)#
network 180.0.0.0
(config-router)#
bgp default local-preference
50
Thus routes which are advertised by both these routers, there will be
preference for the route by the router which has a larger value of the
local-preference parameter.
Topology
The basic topology is defined below, where AS1 is connected to E0, AS2 to
S0, and AS3 to S1.