Post

iBGP with Route Reflector


iBGP, or Internal Border Gateway Protocol, is a type of BGP used to exchange routing information within an Autonomous System (AS), typically in a private network or within an organization.

In traditional iBGP configurations, all routers within the same AS must maintain a full mesh of iBGP peering sessions, meaning that each router needs to be directly connected to every other router in the AS. This is obviously not scalable for large scale of network. That’s where Route Refelctor comes in as an additional part of iBGP network configuration acting as the central routing information for every device in the network.



Network Topology

Here’s the topology for this deployment

x



Configuring IP Addresses

First, lets configure the IP Addressing for every node in the network following the topology

xe1

x

xe2

x

xe3

x

xe4

x

xe5

x

xe6

x



Configuring iBGP

To configure iBGP, we have to explicitly state each neighbor address

xe1

1
2
3
4
conf t
router bgp 1
neighbor 1.1.12.2 remote-as 1
neighbor 1.1.13.3 remote-as 1

xe2

1
2
3
4
5
conf t
router bgp 1
neighbor 1.1.12.1 remote-as 1
neighbor 1.1.24.4 remote-as 1
neighbor 1.1.23.3 remote-as 1

xe4

1
2
3
4
5
conf t
router bgp 1
neighbor 1.1.24.2 remote-as 1
neighbor 1.1.45.5 remote-as 1
neighbor 1.1.34.3 remote-as 1

xe5

1
2
3
4
5
conf t
router bgp 1
neighbor 1.1.45.4 remote-as 1
neighbor 1.1.56.6 remote-as 1
neighbor 1.1.35.3 remote-as 1

xe6

1
2
3
4
conf t
router bgp 1
neighbor 1.1.56.5 remote-as 1
neighbor 1.1.36.3 remote-as 1



Configuring iBGP Route Reflector

Looking at xe1, it has advertised one network of 197.1.0.0/24 to iBGP, and can be seen on xe2

x


But by design, iBGP will only advertise network to one next hop router, which can be seen here on xe4 where it still doesn’t know the existence of the 197.1.0.0/24 network

x


Same goes with network advertised on xe6, only xe5 as the next hop router receives the advertised network, but not the serveral next hops

x


To overcome this, we’ll add one more router (xe3) to act as the Route Reflector, first configure the iBGP to have neighborship to all routers

1
2
3
4
5
6
7
conf t
router bgp 1
neighbor 1.1.13.1 remote-as 1
neighbor 1.1.23.2 remote-as 1
neighbor 1.1.34.4 remote-as 1
neighbor 1.1.35.5 remote-as 1
neighbor 1.1.36.6 remote-as 1


Next configure it to be the route reflector for all neighbors

1
2
3
4
5
6
7
conf t
router bgp 1
neighbor 1.1.13.1 route-reflector-client
neighbor 1.1.23.2 route-reflector-client
neighbor 1.1.34.4 route-reflector-client
neighbor 1.1.35.5 route-reflector-client
neighbor 1.1.36.6 route-reflector-client


Running “show ip bgp summary” on xe3, we can see it now has neighborship to all routers, and it also has learned the advertised network on xe1 and xe5 because they’re only one hop away

x


And now on xe4, it will receive the network advertisements from the route reflector

x



Configuring OSPF

We still have one problem, on xe4 if we see the advertised networks, the next hop is the address original router who advertised the network (xe1 and xe6), which xe4 doesn’t have the route to reach them

x


This is another “cool” design of iBGP where when it re-advertises a network, it keeps the next-hop address of the original advertiser, one way to solve this is by running command “next-hop-self” on each and every router chosen as the next hop, but it is a tideous work and obviously not scalable.
The other way to solve this is by running OSPF to make all routers have route to reach each other.


Run this command on all routers to establish OSPF neighborship

1
2
3
conf t
 router ospf 1
  network 1.1.0.0 0.0.255.255 area 0


And now the OSPF neighborship has been established and all routers can reach each other

x


And now xe4 can reach both xe1 and xe6

x


And it can also reach the advertised networks

x


If we dive more on the routes used, we can see that xe4 learns the 197.1.0.0/24 network from BGP, but in order to get to the next hop which is on xe1, it uses OSPF to learn the route

x



This post is licensed under CC BY 4.0 by the author.