03-10-2009 02:55 PM - edited 03-04-2019 03:53 AM
Our network is setup as such:
ROUTER A------> 4Mbps
ROUTER B------> 4Mbps
We are currently running BGP between the routers. both these routers are connected to l3 switches and are in same lan.
Please find the attached network diagram.
now my requirement is Router A has to allow all other region traffic, and router B has to allow only china region traffic.
can some body pls give me the solution.
03-11-2009 01:11 AM
setup a route-map, match china prefixes and advertise default route to Router-B and for all other prefix advertise default route to Router-A
03-11-2009 01:49 AM
Hello Chaitu,
RA and RB are the exit points towards other locations and they speak BGP to each other.
What is the routing protocol you use between RA and RB and the l3 switches ?
as already suggested you need to make RA more attractive for traffic destined to ip prefixes belonging to other regions and RB preferred for China region prefixes:
if you use iBGP between RA, RB and the l3 switches you need to use the local preference BGP attribute:
default value is 100 and the higher value is preferred
you can set the local preference on RA and Rb
RA:
let's suppose net 10.10.0.0/16 10.11.0.0/16 represent the other regions prefixes
access-list 11 permit 10.10.0.0 0.0.255.255
access-list 11 permit 10.11.0.0 0.0.255.255
route-map rise_locpref permit 10
match ip address 11
set local-preference 200
route-map rise_locpref permit 20
! empty block to allow other prefixes unchanged
router bgp 100
neighbor l3switch-ipaddr route-map rise_locpref out
for RB
let's suppose 10.20.0.0/16 is china region
access-list 12 permit 10.20.0.0 0.0.255.255
route-map rise_locpref permit 10
match ip address 12
set local-preference 200
route-map rise_locpref permit 20
! empty block to allow other prefixes unchanged
router bgp 100
neighbor l3switch-ipaddr route-map rise_locpref out
this should work if l3 switches with direct iBGP sessions are more then one you need to apply the same route-map outbound to all them
Hope to help
Giuseppe
03-11-2009 12:55 PM
that was so kind of you Giuseppe :)
03-12-2009 05:22 AM
Hi,
Thanks for your quick response,
in between l3 switches and routers we are using EIGRP, and all the local subnets will be redistributed to BGP.
is the steps that you explained will work in eigrp scenario also?
second doubt was: if any one of link fails does the active router take the routes of failed routers ?
03-12-2009 05:53 AM
Hello Chaitu,
>> in between l3 switches and routers we are using EIGRP, and all the local subnets will be redistributed to BGP
>> is the steps that you explained will work in eigrp scenario also
Unfortunately, it doesn't.
A different configuration is needed.
Actually you can keep the BGP config of first post but you need to add what follows
different approaches are possible here:
let's suppose both routers send an EIGRP default route to layer3 switches.
traffic can be sent by l3 switches directly to the right router if:
every router redistributes in EIGRP only the specific routes that are preferred on it if they are received by the expected BGP next hop
access-list 11 permit 10.10.0.0 0.0.255.255
access-list 11 permit 10.11.0.0 0.0.255.255
! to check BGP next hop, example
access-list 77 permit host 192.168.2.1
you need to create a new route map to be used for redistribution into EIGRP
route-map bgp-into-eigrp permit 10
match ip address 11
match ip next-hop 77
router eigrp 100
! you need to set a default-metric
default-metric 10000 1000 255 1 1500
redistribute bgp 100
on the other router you need to redistribute the routes of the china region and only if they arrive from the right eBGP neighbor
this check answers to your last question
other variations are possible:
you can use a second block to advertise china region routes with an higher metric from R1 and the other routes from R2.
or you can use a dedicated link between the two routers to run iBGP over it and let to them the duty to decide the right exit point sending only default route in EIGRP
I prefer the first solution with route details injected in EIGRP.
Hope to help
Giuseppe
Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: