This topic is to discuss the following lesson:
Awesome work !!!
Well Done man. I was reading the same topic on the TCP/IP Vol II but the topology used there was quite confusing. Here you used a simple topology and explained to concept of it in a nice and clean way.
Glad to hear it was useful to you, I did my best to keep it as simple as possible.
Great job Rene… This cant get any simpler than this… Finally I learned confederation… Was not able to answer this in so many interview…Now I’m confident
Glad to hear that Abhishek
Very nice explanation Rene… Also can you please add some topics on AS_Confederation_SET and AS_Confederation_Seq
Thanks Taslim. I’ll add these two topics to my list.
Hello there! I noticed that you also have OSPF running. Is there any type of redistribution going on here?
No redistribution configs was listed, so I am just wondering. Can you please explain?
We require an IGP when we run IBGP to advertise loopback interfaces that are used for the neighbor adjacency. Take a look at this lesson, it explains everything:
Thanks Rene , keep going man
Nice explanation. I am bit confused about the use of the command bgp confederation identifier 2
Should we use this command only to that router (R2) connecting to EBGP peers-R1 (the External Autonomous System, in this case 1 )?
Or should we use the command also in the routers connecting to Sub-AS (inside the IBGP)?
I saw you have used the command in all Routers. But do we need to use in all the sub-as routers? I am bit confused. Your help is highly appreciated.
You have to configure this on all routers within the sub-AS otherwise they won’t consider themselves part of the confederation. They will be able to establish BGP peerings but they’ll consider other routers in the confederation as regular “external” or “internal” neighbors. They will also drop routes when they see a confederation path in it.
I tested this, here is the output of some show commands when I removed “bgp confederation identifier 2” on R3, R4 and R5:
R3#show ip bgp 126.96.36.199 BGP routing table entry for 188.8.131.52/32, version 19 Paths: (1 available, best #1, table default) Flag: 0x820 Advertised to update-groups: (Pending Update Generation) 3 Refresh Epoch 1 (24) 1 192.168.12.1 (metric 2) from 184.108.40.206 (220.127.116.11) Origin IGP, metric 0, localpref 100, valid, external, best rx pathid: 0, tx pathid: 0x0
R4#show ip bgp 18.104.22.168 BGP routing table entry for 22.214.171.124/32, version 20 Paths: (1 available, best #1, table default) Advertised to update-groups: 1 Refresh Epoch 1 1 192.168.12.1 (metric 2) from 126.96.36.199 (188.8.131.52) Origin IGP, metric 0, localpref 100, valid, internal, best rx pathid: 0, tx pathid: 0x0
R5#show ip bgp 184.108.40.206 BGP routing table entry for 220.127.116.11/32, version 25 Paths: (2 available, best #2, table default) Advertised to update-groups: 1 Refresh Epoch 1 24 1 192.168.12.1 (metric 3) from 18.104.22.168 (22.214.171.124) Origin IGP, metric 0, localpref 100, valid, external rx pathid: 0, tx pathid: 0 Refresh Epoch 1 (24) 1 192.168.12.1 (metric 3) from 126.96.36.199 (188.8.131.52) Origin IGP, metric 0, localpref 100, valid, internal, best rx pathid: 0, tx pathid: 0x0
Here’s one of the errors I noticed:
R4# %BGP-6-ASPATH: Invalid AS path 35 (24) received from 184.108.40.206: Confederation AS-path found in the middle
Hope this helps.
Thanks for the information. Yes that is correct.
However, I simulated a similar lab like yours but I have not connected R4 and R5 that you have done, only to see if those router can communicate with R1. And i found out that if i don’t connect R4 and R5 to each other as redundant link then those two router do not need the “bgp confederation peer” and “bgp confederation identifier” commands. Also I found out that those two commands are mandatory for R2 and R3. Since, R2 is connecting External AS router R1 and Internal “sub-as” router R3 and R3 is connecting internal “sub-as” router R2 so these R2 and R3 routers need those commands.
I truly appreciate your help to clear my concept on BGP confederation…
I guess you could make that work, R5 would probably see R2 as a regular iBGP neighbor that advertises an external route (from R1). The question is, why would you want this? As soon as they do learn something with a sub-as path then they’ll refuse the route. Better to just add the confederation identifier (and peers) to all devices in the confederation.
Thank you for this article.
I had a question though
When R1 advertises route to R2 that’s external and learned via ebgp. For ibgp protocol states that next hop advertised by ebgp should be carried into ibgp. So when R1 advertises 220.127.116.11 to R2 it uses next hop address as 192.168.12.1. So when R2 advertises this route to its ibgp peers it should have next hop as 192.168.12.1 and not as 18.104.22.168 .
Is this case we can also use next-hop-self command ? or using igp like ospf is the only option?
Yes, you can absolutely use the next-help-self option with iBGP. In fact, in some circumstances you might HAVE to. For example, let’s say you have a router (R1) with an external BGP relationship with an ISP, and your highly available site has been given two separate circuits from that ISP. To ensure that R1’s BGP neighborship with the ISP is also highly available, you have configured R1 to use the ISP’s router’s loopback address (you would also have to use the ebgp-multihop option for this). To do this you would create static routes on R1 to get to the ISP’s loopback through both of your circuits.
Now, suppose that R1 also has an iBGP relationship with other routers you have inside your company (say, R2 and R3). What would happen to all the routes that R1 would learn from the ISP, when it shares them with R2 and R3? The answer is that the routes would not appear in the routing table, and the reason is the next-hop attribute associated with the routes.
In order for BGP to consider a route valid, the very first thing it checks for is the reachability of the next-hop address. From the perspective of R2 and R3, they have no idea how to get to the loopback of the ISP’s BGP router. The best way to fix this would be to do what you said–turn on the “next-hop-self” option for R1.
Excellent Work Rene ! Simple and precise.
Both are working on the same manner in order to overcome the drawback of IBGP full mesh…what is the difference between route reflector and bgp confederation??..
Route reflectors solve the IBGP full mesh issue by using a central RR that has clients, instead of a full mesh.
Confederations reduce the IBGP full mesh by chopping an AS into multiple sub-ASes. Keep in mind that each sub-AS still has the full mesh IBGP requirement, or you can use RRs within a sub-AS.
Both options have (dis)advantages so it depends on your network design if you use one or both options.