EBGP Multihop

This topic is to discuss the following lesson:

Rene,
I thought multi-hop is only when we have two BGP neighbors are not directly connected. I can see in the example when loopback addresses are used to configure BGP neighbors you are using multi-hop command even thoug the routers are directly connected.
In the first example and your note says having non BGP router between two BGP routers is not a good idea. For instance if we have no choice then how can we make sure R1 and R3 networks are reachable?
Please clarify.

Thanks
Hamood

Hi Hamood,

That’s right, if you source eBGP from the loopback interfaces then you’ll need multihop.

The problem with the R1-R2-R3 scenario is that R2 will never learn about any prefixes, when R1 tries to reach a network behind R3 (or R3 wants to reach something behind R1) then R2 will receive an IP packet with a destination it doesn’t know about.

If you really had to use eBGP between R1 and R3 then a GRE tunnel might be a solution…

Rene

1 Like

Hello Rene,

If we use static routes then why we use BGP? couldn’t we advertise the subnets with network command in BGP?

Thanks,
-Rouzbeh

1 Like

Hi Rouzbeh,

In the example with the two interfaces, we use static routes only for the neighbor adjacency. Once BGP is up and running, we’ll use it to advertise networks. With only two routers there’s no need to run BGP, just imagine that R1 and R2 are part of a much larger network with multiple ASes, routers, etc. :slight_smile:

Rene

3 Likes

Is BGP neighbor command not enough to build the adjacency? I mean with 2 routers static route is mandatory?

Thanks,
-Rouzbeh

1 Like

Hi Rouzbeh,

If you are using the IP addresses on the directly connected links then yes, all you need is the neighbor command. If you establish it between two loopback interfaces then your routers need to know how to reach each other’s loopback interface.

Rene

True, but my question is if the loopbacks are learned by routing tables which they are because they are directly connected then BGP will learn them as well, please correct me if I am wrong.

Thanks,
Rouzbeh

1 Like

Hi Rouzbeh,

The static routes are required otherwise there’s no way to create the BGP neighbor adjacency between the loopbacks. The routers don’t know how to reach each others loopbacks. Once the BGP neighbor adjacency, you could advertise the loopbacks but they will never be installed in the routing table since the static routes have a lower AD.

Rene

3 Likes

understood, thank you so much Rene

“ip route 192.168.12.1 255.255.255.255 192.168.23.2”

Hi Rene, in the above statement, why are you using a 32 bit mask while you only have a /24 configured on the interface?

Hi Kam,

I did this because the router only needs to know how to reach this particular IP address, it doesn’t matter if you use a /24 or /32 in this example :slight_smile:

Rene

Hi Rene is there any config where we can use (ebgp-multihop 1)?

Hi Madimba,

Not really, the default TTL for BGP is 1 so you’ll need at least a TTL of 2 when you configure ebgp-multihop.

Rene

1 Like

Hi Rene,

Why you enable the directly connected check again when you increase the TTL ?

thanks.

1 Like

By default the TTL for eBGP is 1. If you want to get around this then you can disable “disable-connected-check” or you can increase the ebgp multihop. Both options will work and it’s one of the two that you should use.

To demonstrate multihop, I enabled the disable-connected-check again. Otherwise there would be no point demonstrating it :slight_smile:

thanks Rene I understood that we have tow options to use, but in the first option they will not become neighbor even though “disable-connected-check” since by default the TTL for eBGP is 1 so finally we need to increase the TTL if we use the first option ? right ?

1 Like

in the other word what is the benefit of disabling connected check, since when we increase the TTL the routers will know that they are not direct contacted ?

Hi Hussein,

Disabling the connected-check is only useful when you have two routers and you want to connect through eBGP using their loopback interfaces. This is the only scenario where it will work. If the routers are not directly connected then you always have to increase the TTL, there’s no point disabling the connected check then.

There’s not really any benefit “over” increasing the TTL, both will work.

Rene

Hi Rene,

What do you think to create a GRE tunnel between R1 and R3 so that BGP neighbors can reach the other one? Is that possible? I think in this way R2 doesn’t have to know anything about the BGP routes.

Thanks