EBGP Multihop

• Use eBGP multihop when remote eBGP neighbor is not directly connected

Syntax:

router(config-router)# neighbor {ip-address / peer-group-name} ebgp-multihop max-hop-count router(config-router)# neighbor {ip-address / peer-group-name} ebgp-multihop max-hop-count

Usually, the two eBGP speakers are directly connected (for example, over a Wide Area Network (WAN) connection). Sometimes, they cannot be directly connected, such as the case when a router that does not use BGP is in between the two neighbors that wish to form an eBGP neighbor relationship. In this special case, the neighbor ebgp-multihop router configuration command is used. Without this command, an eBGP neighbor relationship with a non-directly connected neighbor will never form. Remember, this command is only used with eBGP, not iBGP.

sco.com sco.com

R4(config)# router bgp 100

R4(config-router)# neighbor 172.16.56.6 remote-as 200 R4(config-router)# neighbor 172.16.56.6 ebgp-multihop

R4(config-router)# exit

R4(config)# ip route 172.16.56.0 255.255.255.0 172.16.45.5

R6(config)# router bgp 200

R6(config-router)# neighbor 172.16.45.4 remote-as 100 R6(config-router)# neighbor 172.16.45.4 ebgp-multihop

R6(config-router)# exit

R6(config)# ip route 172.16.45.0 255.255.255.0 172.16.56.5

© 2002, Cisco Systems, Inc. All lights reserved.

Cisco CCIE Prep v1.0—Mod neighbor {ip-address / peer-group-name} ebgp-multihop max-hop-count

Look at the previous example where R5 is a non-BGP speaking router. R4 and R6 wish to form an eBGP neighbor relationship.

Notice that both routers reference their external neighbor by an Internet Protocol (IP) address that is not directly connected. A requirement of BGP is reachability, so an ebgp-multihop configuration must include static routes or must enable an IGP so that the neighbors can reach each other.

eBGP Load Balancing

• To load balance use eBGP-multihop in conjunction with update-source loopback

It is possible to have a situation where an ebgp-multihop router configuration is useful together with loopbacks. Using these two features enables you to perform load balancing between two autonomous systems over parallel links.

R4(config)# interface loopback 0

R4(config-if)# ip address 4.4.4.4 255.255.255.0 R4(config-if)# router bgp 100

R4(config-router)# neighbor 5.5.5.5 remote-as 200 R4(config-router)# neighbor 5.5.5.5 ebgp-multihop R4(config-router)# neighbor 5.5.5.5 update-source loopback 0 R4(config-router)# network 4.4.4.0 mask 255.255.255.0 R4(config-router)# exit

R4(config)# ip route 5.5.5.0 255.255.255.0 172.16.44.5 R4(config)# ip route 5.5.5.0 255.255.255.0 172.16.45.5

R5(config)# interface loopback 0

R5(config-if)# ip address 5.5.5.5 255.255.255.0 R5(config-if)# router bgp 200

R5(config-router)# neighbor 4.4.4.4 remote-as 100 R5(config-router)# neighbor 4.4.4.4 ebgp-multihop R5(config-router)# neighbor 4.4.4.4 update-source loopback 0 R5(config-router)# network 5.5.5.0 mask 255.255.255.0 R5(config-router)# exit

R5(config)# ip route 4.4.4.0 255.255.255.0 172.16.44.4

R5(config)# ip route 4.4.4.0 255.255.255.0 172.16.45.4

Look at R4's BGP route table:

R4# show ip bgp

BGP table version is 3, local router ID is 172.16.45.4

Status codes: s suppressed, d damped, h history, * valid, > best, i - internal Origin codes: i - IGP, e - EGP, ? - incomplete

Network Next Hop Metric LocPrf Weight Path

Notice that the route to 5.5.5.0/24 is via 5.5.5.5 as the next hop. Look at what the IP routing table looks like for this route:

R4# show ip route

Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2 E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area * - candidate default, U - per-user static route, o - ODR P - periodic downloaded static route Gateway of last resort is not set

4.0.0.0/24 is subnetted, 1 subnets C 4.4.4.0 is directly connected, Loopback0

5.0.0.0/24 is subnetted, 1 subnets S 5.5.5.0 [1/0] via 172.16.44.5

[1/0] via 172.16.45.5 172.16.0.0/24 is subnetted, 2 subnets C 172.16.44.0 is directly connected, Serial1/0

C 172.16.45.0 is directly connected, Serial1/1

The neighbor ebgp-multihop and neighbor update-source router configuration commands have the effect of making the loopback interface the next hop for eBGP, which allows load balancing to occur. You can use static routes to introduce two equal-cost paths to the destination. (The same effect could also be accomplished by using an IGP.) R4 can reach the next hop of 5.5.5.5 in two ways: via 172.16.44.5 and via 172.16.45.5. Also, R5 can reach the next hop of 4.4.4.4 in two ways: via 172.16.44.4 and via 172.16.45.4.

+5 0

Post a comment