cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1925
Views
0
Helpful
2
Replies

why do i need to use the update-source loopback 0 command in bgp ?

huangzhy
Level 1
Level 1

In bgp's config,the sender id of bgp packet is a 4-byte integer that indicates the sender's ID,which is usually the router ID(RID). And the router ID is the highest IP address on the router or the highest loopback address ,so if i have config the loopback interfce in the router ,it's the router ID, and the bgp sender's id at the same time ,and any bgp packet will have the loopback interface as the sender ID,so why do i need to specify "neighbor update-source loopback 0" command?

2 Replies 2

thisisshanky
Level 11
Level 11

You need to specify that command, only in specific situations like one of these...

You have two AS, with router A in AS 1 and router B in AS 2. You have two serial links between them. When you peer using BGP using the neighbor statements, you have two ip addresses, which can be used, that of link 1 (assume s0 to s0 ) and that of link 2 (s1 to s1). S0 and s1 are the serial interface of the routers.

If you peer using any of these physical addresses, if the link fails (the link whose ip address has been used for peering), BGP peering will fail, because that interface is down.

Loopback interfaces are software ints. which are always Up. To take advantage of that in this situation, we can configure two loopbacks, one each on A and B, and peer using that ip address in BGP. But just using the loopback addresses, in peering wont, work because, BGP validates the source address of the updates coming from the neighbor.

So, when A peers with B using B's loopback address, source address of update packet,sent by A to B, would be serial0 address of A and destination address would be loopback 0 address of B. But when B receives the packet, it checks its neighbor statements, and sees that the neighbor address that is configured in B, is the loopback 0 address of A and not the serial 0 address of A. So B ignores the packet, and thus the source address is invalidated, and connection fails. In such a scenario, if the source address of the update packet is modified as loopback 0 address of A, BGP connection will succeed.

Hope my explanation is clear!

Sankar Nair
UC Solutions Architect
Pacific Northwest | CDW
CCIE Collaboration #17135 Emeritus

Thanks!

What you explain is clear to me.

Review Cisco Networking for a $25 gift card