PermitANY
AristaConfig756 downloads

Arista EOS BGP Configuration

eBGP and iBGP routing for Arista EOS with peer groups, route-maps, prefix-lists, communities, and multi-path ECMP support.

↓ example.txt

What is it?

Arista BGP uses the familiar Cisco IOS-like syntax with peer-groups and neighbor configuration. A key Arista feature is 'bgp bestpath ecmp-fast' and 'maximum-paths' — enabling ECMP load-balancing across multiple BGP paths, critical for data center spine routing. Arista is widely deployed as a data center BGP route reflector and spine switch where it must handle full BGP tables with high throughput. EOS also supports BGP unnumbered (using IPv6 link-local addresses) for simplified cabling in large fabrics.

When to use

  • ·Internet edge routing with ISP eBGP peering
  • ·Data center spine-leaf routing where spine acts as BGP route reflector
  • ·Multi-homed deployments needing traffic engineering with AS-path or local-preference
  • ·BGP EVPN overlay (covered in the bgp-evpn template) — this template covers the base BGP config

When NOT to use

  • ·Internal campus routing — use OSPF for simpler IGP routing
  • ·Very small networks — a static default route is less complex than BGP

How it compares

vs Cisco IOS BGPArista BGP syntax is almost identical to Cisco IOS. Key differences: Arista uses 'maximum-paths X ecmp X' for ECMP; IOS uses 'maximum-paths X'. Arista's 'bgp bestpath ecmp-fast' is specific to EOS for faster ECMP convergence.
vs Juniper BGPJuniper uses policy-statements for filtering (more powerful). Arista uses IOS-style route-maps. Arista is easier to configure for engineers with Cisco background; Juniper gives more flexibility for complex filtering.

Prerequisites

  • →Router ID should be a stable loopback address
  • →For iBGP: OSPF or IS-IS underlay must be running so iBGP next-hops are reachable
  • →AS number decided — use private AS (64512-65534) for iBGP / internal BGP, public AS for ISP peering
  • →Route-maps should be created before referencing them in neighbor config

Config Generator

Verification commands

show bgp summary

Show all BGP peer states and prefix counts

ExpectedPeers show 'Estab' state with non-zero 'PfxRcd'. 'Active' or 'Idle' means session not up.

show ip bgp

Show full BGP table with all paths and best-path selection

ExpectedBest path marked with '>'. ECMP paths marked with '='. Next-hop should be reachable.

show bgp neighbors <peer-ip> advertised-routes

Verify which routes are being advertised to a specific peer

ExpectedLists routes being sent to peer. Empty means export policy or network statement missing.

Debug commands

show bgp neighbors <peer-ip>

Show detailed BGP session state and error messages

Common mistakes & fixes

SymptomBGP session stuck in 'Active'
CauseTCP 179 not reachable, wrong peer IP, or AS number mismatch
FixTest connectivity: 'ping <peer-ip> source <local-ip>'. Verify peer's remote-as matches the actual AS of the remote device.
SymptomRoutes in BGP table but not installed in routing table
CauseNext-hop not reachable (common with iBGP without next-hop-self)
FixEnable 'next-hop-self' on iBGP peer groups, or ensure the IGP has a route to the iBGP peer's next-hop.
SymptomECMP not working — traffic only using one path
Cause'maximum-paths' not configured or 'bgp bestpath ecmp-fast' missing
FixAdd 'maximum-paths <n> ecmp <n>' under 'router bgp'. Verify multiple paths exist: 'show ip bgp <prefix>' should show multiple '=' entries.

Further learning

Recommended books to go deeper on this topic.

BGP Design and Implementation

Randy Zhang & Micah Bartell · Cisco Press · The practical BGP bible — iBGP, eBGP, policies, communities, design patterns

Internet Routing Architectures

Sam Halabi · Cisco Press · BGP for ISPs and large enterprise — AS path, route reflectors, confederation

Related configs