Pcornel
Networking · Routing › Routing Table

BGP (Border Gateway Protocol)

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

Back to the Topic

Answer

A BGP route must pass several boundaries before it forwards traffic: the path is learned into the BGP table, selected as best, offered to the global/VRF RIB, wins against competing routing sources, and has a resolvable next hop for FIB programming. Cisco default administrative distance commonly favors eBGP at 20 and treats iBGP as 200, but policy and platform context still determine which candidate becomes active.

Remember

B routes have AD 20 when learned from eBGP and 200 from iBGP — so an iBGP route loses to any IGP route for the same prefix. A B line shows only a next-hop address, no interface: the router resolves it recursively through another route. r in show ip bgp (RIB-failure) means another source won the routing table.

First checks

show ip route <prefix> → source bgp, distance 20 or 200, next hop. show ip bgp <prefix> → best path and its next hop. show ip bgp rib-failure → BGP best paths that were not installed. show ip cef <prefix> → the resolved interface.

Commands

show bgp ipv6 unicast summary
Lists the IPv6 unicast BGP neighbors with state, up time and number of prefixes received.
show ip bgp
show ip route
show ip bgp rib-failure
show ip bgp <prefix>
show ip bgp neighbors <ip> received-routes
show bgp ... received
show ip bgp summary
show bgp

Verify in this order

path in the BGP table → valid (next hop reachable) → best → offered to the RIB → lowest AD wins (eBGP 20, iBGP 200) → B entry → next hop resolved recursively → CEF

Where it usually breaks

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

BGP operational reference

BoundaryKnown-good for BGPSuspicious signatureNext proof
IntentMatches BGP RIB interpretation designConfiguration differs from peer/designCompare effective config
Control stateStable expected role/route/member statea BGP best path absent from the RIB, unresolved NEXT_HOP, a lower-AD IGP/static route winning, or a route installed but forwarding toward the wrong recursive adjacencyInspect protocol/RIB detail
ForwardingExpected egress/Port-Channel/VLAN pathState exists but traffic path disagreesFIB/MAC/adjacency
ClosureOriginal test passes for explained reasonSymptom merely moved or was bypassedRegression test

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

Confirmation

Confirm action

Continue?