Pcornel
Networking · Routing

BGP (Border Gateway Protocol)

Cheat sheet · https://pcornel.dk/topic.php?topic=638

Back to the Topic

Answer

Border Gateway Protocol (BGP) is a path-vector interdomain routing protocol. It exchanges network reachability plus path attributes over a TCP session instead of discovering shortest paths from a shared topology database.

Remember

  • BGP uses TCP port 179
  • The session, prefix, best path, RIB installation and forwarding plane are separate evidence boundaries
  • BGP policy changes what is accepted, advertised and preferred
  • An Established peer proves message exchange is possible; it does not prove the required prefix exists or forwards
  • Follow BGP Fundamentals, eBGP, iBGP, BGP Path Selection and BGP Communities/Route Policy; common attributes apply across the AS boundary.

First checks

1. Prove IP reachability to the peer with the intended source.

2. Check BGP session state.

3. Check whether the exact prefix is present.

4. Compare path attributes and the selected best path.

5. Verify BGP route installation in the RIB.

6. Continue to CEF/adjacency, policy and return-path evidence if traffic still fails.

Commands

show ip bgp summary
3
show ip bgp
4
show bgp ipv4 unicast
4
show ip route bgp
6
clear ip bgp
clear ip bgp <neighbor> soft
show bgp ipv4 unicast summary
show route-map
show bgp ipv4 unicast <prefix>
show ip route <prefix>
show bgp ... rib-failure
show ip bgp <prefix>
show ip cef <prefix>

Verify in this order

peer reachable from the peering source → session Established → prefix received → valid and best path → routing table → CEF → traffic and return path

Where it usually breaks

underlay/interface reachability → protocol adjacency/session → received/originated state → policy → best path/RIB → FIB/adjacency → traffic path

Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=638

Confirmation

Confirm action

Continue?