The disable-connected-check was created precisely for the purpose of peering two directly connected routers on their loopbacks without using the ebgp-multihop.
By default there are two precautions when establishing eBGP neighborships:
- Check whether the client is on a directly connected network. If it is not, there won’t be any attempt to form the neighborship. This check can be deactivated on a per-neighbor basis using the neighbor disable-connected-check
- The default TTL value for the packets carrying the BGP messages is 1 unless we configure ebgp-multihop to modify the TTL value. If the ebgp-multihop is configured, the router automatically and implicitly behaves to the neighbor as if the disable-connected-check was configured. In other words, using ebgp-multihop automatically implies disable-connected-check
Related- Troubleshooting indirectly connected eBGP neighbors
Disable-connected-check is not used when we use either TTL-security or eBGP multihop with a numerical argument of 2 or greater hops. In these cases, it automatically gets activated and doesn’t require specific configurations. This is configured under the router BGP process along with the neighbor statement.
Related- TTL Security in BGP
Below scenario will help understand the concept of “Disable-Connected-Check” in a more detailed way –
The devices R1 and R2 are arranged as per the above-shown diagram.
ip address 22.214.171.124 255.255.255.255
ip address 126.96.36.199 255.255.255.0
router bgp 100
neighbor 188.8.131.52 remote-as 200
neighbor 184.108.40.206 disable-connected-check
neighbor 220.127.116.11 update-source Loopback0
ip route 18.104.22.168 255.255.255.255 22.214.171.124
ip address 126.96.36.199 255.255.255.255
ip address 188.8.131.52 255.255.255.0
router bgp 200
neighbor 184.108.40.206 remote-as 100
neighbor 220.127.116.11 disable-connected-check
neighbor 18.104.22.168 update-source Loopback0
ip route 22.214.171.124 255.255.255.255 126.96.36.199
R1#sh ip bgp summary
BGP table version is 1, main routing table version 1
Neighbor V AS MsgRcvd MsgSent TblVer InQ OutQ Up/Down State/PfxRcd
188.8.131.52 4 200 7 7 1 0 0 00:02:57 0
As shown above , neighborship over Loopbacks is being formed without need of “eBGP Multihop” configuration requirement .
Related- BGP Multipath Scenario