CLOUD CONCEPT

Equal-Cost Multipath Routing

Equal-Cost Multipath Routing distributes traffic across multiple eligible network paths that have equal routing preference to the same destination.

Cloud Concepts Hub →

What is Equal-Cost Multipath Routing

Equal-Cost Multipath Routing, commonly called ECMP, allows a router to use several equivalent next hops rather than selecting only one. It can improve aggregate bandwidth utilization and resilience, but it does not normally combine multiple links into a faster path for a single traffic flow.

Equal-Cost Multipath Routing is a forwarding technique that uses multiple equally preferred routes to the same destination prefix. Here, “cost” means routing preference or metric, not the financial price of a connection. Depending on the routing protocol and implementation, routes must have compatible metrics and path attributes before they can participate in ECMP. Two connections reaching the same network do not automatically form an ECMP group.

Most implementations distribute traffic using a hash of packet fields, such as source and destination addresses, protocol, and transport ports. Packets belonging to a flow normally follow the same path, reducing packet reordering. With enough independent flows, several links can carry traffic simultaneously. However, traffic distribution is not necessarily even: a few large transfers can saturate one path while another remains underused.

For example, two eligible 1 Gbps paths can provide close to 2 Gbps of aggregate capacity under favorable conditions when many flows are distributed across them. A single TCP connection usually remains limited to one path’s capacity. Protocol overhead, packet loss, latency, encryption processing, and endpoint performance can reduce achieved throughput further. Adding paths therefore helps a workload containing many independent connections more predictably than a workload consisting of one large transfer.

In cloud networks, ECMP commonly applies to hybrid connectivity through multiple VPN tunnels or private connectivity circuits. Dynamic routing, frequently using Border Gateway Protocol, advertises destination prefixes and withdraws routes when connectivity fails. The cloud routing service and the customer router must both support the intended multipath behavior. Forward and return traffic are selected independently, so engineers must also consider asymmetric routing through stateful firewalls or other appliances.

For AWS architectures, AWS Transit Gateway supports ECMP across eligible dynamically routed AWS Site-to-Site VPN tunnels when VPN ECMP support is enabled. Static-routing VPN connections do not support this ECMP capability. A virtual private gateway does not support ECMP for Site-to-Site VPN, so simply adding VPN connections to that gateway does not aggregate their bandwidth. The two tunnels included with a VPN connection provide redundancy, but their presence alone does not establish that both will carry traffic concurrently.

Bandwidth selection should start with aggregate demand, largest-flow requirements, and the capacity required during a failure. Multiple VPN paths can be appropriate when parallel application traffic needs more aggregate throughput than one tunnel provides. A higher-speed private connection, such as AWS Direct Connect, may be more appropriate when a workload needs greater per-path capacity or more consistent network performance. Multiple Direct Connect connections can also support ECMP in supported configurations, but their routing attributes and gateway topology must qualify.

Cost optimization requires comparing the complete architecture rather than counting links alone. Include VPN connection charges, transit processing, private circuit and port charges, data transfer, customer equipment, and operational effort. Also avoid provisioning only enough combined capacity for normal operation: if two paths are both nearly full, losing one causes congestion even though routing successfully fails over. Validate the design with multiple concurrent flows, inspect utilization per path, and test route withdrawal and recovery before relying on the advertised aggregate bandwidth.

Key aspects of Equal-Cost Multipath Routing

ECMP combines equally preferred routes for aggregate capacity and resilience, subject to flow hashing, routing eligibility, failure capacity, and end-to-end platform support.

Equal routing preference

Only routes that qualify as equally preferred under the platform’s routing rules can share traffic. Matching destination prefixes, routing metrics, and relevant BGP attributes matter; equal link speeds alone do not establish ECMP.

Flow-based traffic distribution

Most implementations hash flow attributes to select a next hop and keep that flow on one path. Aggregate throughput can increase across many flows, but an individual flow generally cannot exceed one path’s capacity.

Active-active bandwidth utilization

ECMP can use several eligible paths concurrently instead of reserving all secondary paths for standby operation. Verify actual per-path utilization because hashing does not guarantee equal bandwidth consumption.

Failure-aware capacity planning

When a route is withdrawn, traffic can move to remaining eligible paths after failure detection and routing convergence. Provision enough surviving capacity to handle the required workload, rather than assuming successful failover prevents congestion.

End-to-end implementation requirements

Cloud gateways, customer routers, route advertisements, and security appliances must support the intended design. Forward and return path selection can differ, which matters when traffic crosses stateful devices.

Workload-driven cost optimization

Compare multiple smaller paths with a higher-capacity path using aggregate demand, single-flow requirements, and total connectivity charges. Additional tunnels or circuits increase useful capacity only when routing eligibility and workload parallelism allow them to be used.

Cloud services for Equal-Cost Multipath Routing

AWS Site-to-Site VPN provides encrypted hybrid paths, while AWS Transit Gateway can distribute traffic across eligible BGP-advertised VPN paths using ECMP. AWS Direct Connect offers private connectivity whose port capacity and supported multipath arrangements provide another bandwidth-sizing option. Compare these designs using aggregate throughput, individual-flow requirements, resilience, and total charges. Customer routers must advertise compatible routes and support the intended forwarding behavior. A virtual private gateway is not interchangeable with Transit Gateway for VPN bandwidth aggregation because it does not support VPN ECMP.

AWS Transit Gateway image AWS Transit Gateway

AWS Transit Gateway supports ECMP across eligible BGP-based Site-to-Site VPN tunnels when VPN ECMP support is enabled. It provides the cloud-side routing capability needed to use multiple qualifying VPN paths concurrently rather than relying only on standby connectivity.

Open AWS Transit Gateway →
AWS Site to Site VPN image AWS Site-to-Site VPN

AWS Site-to-Site VPN supplies encrypted tunnels that can participate in ECMP through Transit Gateway when dynamic routing and the required route attributes are configured. VPN connections attached to a virtual private gateway do not support ECMP, and static-routing VPN connections do not provide Transit Gateway VPN ECMP.

Open AWS Site-to-Site VPN →
AWS Direct Connect image AWS Direct Connect

AWS Direct Connect provides private connectivity with provisioned bandwidth, and multiple connections can support active-active ECMP in supported gateway and virtual-interface configurations. Eligible routes require compatible BGP attributes; purchasing additional circuits alone does not guarantee traffic sharing or increased single-flow throughput.

Open AWS Direct Connect →