OPERATOR REFERENCE · BGP-4

BGP Field Reference
Cisco IOS-XE & Arista EOS

verify → inspect → configure → tune → troubleshoot — one page, two vendors
ROUTER-A · AS 65001
eBGP
ROUTER-B · AS 65002
01 Verify & Inspect

Session Status

Cisco IOS-XE show ip bgp summary show ip bgp vpnv4 unicast summary
Arista EOS show bgp summary show bgp ipv4 unicast summary
State column shows Idle/Active/Connect instead of a prefix count → session is not established.
👥

Neighbor Detail

Cisco IOS-XE show ip bgp neighbors
Arista EOS show bgp neighbors
  • Remote AS, Local AS, Router ID
  • Hold timer / Keepalive timer
  • Negotiated capabilities
  • Time since established

Advertised / Received Routes

Cisco IOS-XE show ip bgp neighbors x.x.x.x advertised-routes show ip bgp neighbors x.x.x.x received-routes
Received-routes needs soft-reconfiguration inbound, or use routes on Arista instead.

Full Table & Lookups

Cisco IOS-XE show ip bgp show ip bgp 10.20.30.0/24
Arista EOS show bgp ipv4 unicast show bgp ipv4 unicast 10.20.30.0/24
Prefix lookup returns next-hop, AS path, local-pref, MED, and origin for that route.

RIB & Next-Hop

Cisco IOS-XE show ip route show ip cef x.x.x.x
Arista EOS show ip route 10.20.30.0

Soft Reset & Clear

Cisco IOS-XE clear ip bgp x.x.x.x soft in clear ip bgp x.x.x.x soft out clear ip bgp x.x.x.x
Arista EOS clear bgp neighbor x.x.x.x soft in | out
⚠ hard clear (no soft) tears the session down

First-Look Diagnostics

  • ping x.x.x.x
  • traceroute x.x.x.x
  • telnet x.x.x.x 179 / nc -zv x.x.x.x 179
  • show bfd neighbors / show bfd peers
  • debug ip bgp (Cisco, use sparingly)
  • debug bgp tcp transactions

Prefix & AS-Path Cheats

  • Prefix filter: ip prefix-list PL-IN permit 10.10.10.0/24
  • Apply: neighbor 192.168.1.2 prefix-list PL-IN in
  • Route-map: neighbor 192.168.1.2 route-map LOCALPREF in
02 Base Configuration
+

Create Neighbor

Cisco / Arista router bgp 65001 neighbor 192.168.1.2 remote-as 65002
af

Address Family

Cisco address-family ipv4 neighbor 192.168.1.2 activate
Arista: IPv4 unicast is enabled by default under most configs.

Advertise a Network

Cisco / Arista network 10.10.10.0 mask 255.255.255.0 network 10.10.10.0/24
First form = Cisco classic syntax, second = Arista / modern syntax.

Update Source

neighbor 192.168.1.2 update-source Loopback0
Required for multihop/loopback peering so the source IP matches.

Timers

neighbor 192.168.1.2 timers 10 30
Default keepalive = 60s, hold = 180s. Format: keepalive hold.

eBGP Multihop

neighbor 192.168.1.2 ebgp-multihop 2
Needed when eBGP peers aren't directly connected (e.g. loopback peering).
🔒

Authentication

neighbor 192.168.1.2 password MyPassword
MD5 auth on the TCP session — must match exactly on both peers.
📡

BFD

Cisco neighbor 192.168.1.2 fall-over bfd
Arista neighbor 192.168.1.2 bfd

Send Community

neighbor 192.168.1.2 send-community
Add extended or both for extended/standard communities.
03 Policy & Path Tuning

Max Prefix

neighbor 192.168.1.2 maximum-prefix 1000
Session drops (or warns) past the limit — set with a safety margin.
🛡

Remove Private AS

neighbor 192.168.1.2 remove-private-as
Strips private ASNs (64512–65534) before advertising outbound.

Default Originate

neighbor 192.168.1.2 default-originate
Injects a 0.0.0.0/0 toward the peer regardless of local table.

Local Preference

route-map LOCALPREF permit 10 set local-preference 200 neighbor 192.168.1.2 route-map LOCALPREF in

AS-Path Prepend

route-map PREPEND permit 10 set as-path prepend 65001 65001 65001 neighbor 192.168.1.2 route-map PREPEND out

Community & Weight

set community 65001:100 neighbor 192.168.1.2 weight 500
Weight is Cisco-only, locally significant, default 32768 for locally-originated routes.
04 Session State Machine
IDLE
waiting to start
CONNECT
TCP in progress
ACTIVE
retrying TCP
OPENSENT
OPEN message sent
OPEN-
CONFIRM
awaiting KEEPALIVE
ESTAB-
LISHED
session up, normal
05 Best-Path Selection Order (Cisco default)
#CriterionRule
1WeightHighest wins (Cisco only, local significance)
2Local PreferenceHighest wins
3Local originationLocally originated route preferred
4AS-Path lengthShortest wins
5Origin typeIGP < EGP < Incomplete
6MEDLowest wins (compared between same neighboring AS)
7Path typeeBGP preferred over iBGP
8IGP metric to next hopLowest wins
9Path ageOldest eBGP path preferred (stability)
10Router IDLowest wins
11Neighbor IPLowest wins — final tiebreaker
06 Attributes & Common Faults

Common Attributes

AttributeDefaultPreference
Weight (Cisco)32768Higher = local route
Local Pref100Higher = within AS
AS-PathShorter path
MED0Lower, from same neighbor AS
eBGP vs iBGPeBGP preferred
IGP MetricLower = closer next hop
Router IDLower wins, final tiebreak

Where to Look

SymptomCheck
Session not upshow bgp summary
Neighbor config mismatchshow bgp neighbors
Missing outbound routeshow bgp neighbors x.x.x.x advertised-routes
Missing inbound routeshow bgp neighbors x.x.x.x received-routes
Prefix not in RIBshow bgp ipv4 unicast x.x.x.x
TCP reachabilitytelnet x.x.x.x 179 / nc -zv x.x.x.x 179
Flapping link/livenessshow bfd peers, debug bgp tcp
07 Why Sessions Won't Establish
Stuck inLikely cause
IDLENeighbor unreachable, wrong config, admin shutdown
ACTIVETCP/179 blocked, ACL or firewall in the path
OPENSENTAS number mismatch, authentication failure
OPENCONFIRMCapability mismatch, timer mismatch
ESTABLISHEDbut 0 prefixes: missing network stmt, prefix-list, or route-map filtering everything
FLAPPINGUnstable link, MTU mismatch, BFD/keepalive too aggressive

Route Types & Ports

  • iBGP — within the same AS
  • eBGP — learned from another AS
  • Incomplete — redistributed, no clean origin
BGP runs over TCP/179. AFI/SAFI: IPv4 unicast = AFI 1 / SAFI 1, IPv6 unicast = AFI 2 / SAFI 1, VPNv4 = AFI 1 / SAFI 128.
Quick lab check: show running-config | section bgp — simulate a link failure to test convergence time and prefix churn.