Subchapter 94.6
references/making-a-connection-highly-available.mdMarkdown10 KBView on GitHub
Domain expertise for keeping an AWS Site-to-Site VPN connection up through tunnel maintenance and on-premises device failure. Covers configuring the on-premises device to use both tunnels (which is free), the BGP attribute settings that let AWS steer traffic to the healthy tunnel during endpoint updates, the second-connection-on-a-second-device pattern for surviving device failure (which adds cost), and the matching-advertisement requirement for clean failover.
Does not cover the routing-type decision (the choosing-static-or-dynamic-routing reference) or monitoring (the monitoring-and-troubleshooting-tunnels reference). Assumes a connection exists (the creating-a-site-to-site-vpn-connection reference).
Execute commands using the AWS MCP server when connected (sandboxed execution, audit logging,
observability). Fall back to the AWS CLI otherwise. Pass --region {region} matching the connection.
To make the connection highly available, configure both tunnels on the device, set matching BGP attributes, and decide whether a second connection on a second device is warranted. See the Procedure section below.
The procedure covers:
Each connection provides two tunnels in different Availability Zones, but the redundancy only works if the device is configured to use both, and customers commonly configure only one. There is no added charge for using both tunnels: the VPN connection price covers both.
Constraints:
This section applies only to connections using dynamic (BGP) routing. For static routing connections, AWS failover during tunnel updates is automatic and does not depend on BGP attributes.
AWS applies tunnel endpoint updates one tunnel at a time and steers traffic to the healthy tunnel using a lower multi-exit discriminator (MED) value. That steering only takes effect if the device uses the same Weight and Local Preference for both tunnels; different values override the AWS preference and send traffic into the tunnel being updated.
Constraints:
Two tunnels protect against an AWS-side device failure, but not against the customer’s own gateway device failing. Surviving the loss of the on-premises device requires a second VPN connection on a separate customer gateway device. This is a real added cost: each connection bills per connection-hour, so a redundant pair roughly doubles the connection charge.
Constraints:
A redundant pair only fails over cleanly when both devices advertise the same prefixes to the target gateway, and BGP is what detects the failure and reroutes. Mismatched prefixes or static routing produce a setup that does not fail over as expected.
Constraints:
Only one tunnel is configured. Configure both (Both tunnels first).
Weight and Local Preference differ between tunnels. Set them equal (BGP attributes for tunnel-update steering).
A single connection does not cover device failure. Add a second connection on a second device (Second device for device failure).
The two devices advertise mismatched prefixes, or static routing is in use. Advertise the same prefixes over BGP (Matching advertisements).
This procedure confirms both tunnels are used, sets matching BGP attributes, and optionally adds a second connection on a second device with matching advertisements, then surfaces the console link to verify tunnel status.
Constraints for parameter acquisition:
Constraints:
aws sts get-caller-identityConstraints:
Constraints:
Constraints:
You MUST configure both devices to advertise the same prefixes over BGP if a second connection is added
You MUST present the VPN connections console link, filling {region} from the request, and tell the customer to open it and confirm both connections and all tunnels:
https://console.aws.amazon.com/vpc/home?region={region}#VpnConnections:{
"region": "us-east-1",
"vpn_connection_id": "vpn-0abc1234def567890",
"needs_device_failover": true,
"second_customer_gateway_ip": "203.0.113.20"
}Both tunnels configured on the primary device (no extra cost), with matching Weight and Local
Preference so AWS steering is honored. Customer accepted the added cost for device-failure
resilience: added a second connection on 203.0.113.20, both devices advertising the same prefixes over
BGP. Open the connections list and confirm both connections and all tunnels:
https://console.aws.amazon.com/vpc/home?region=us-east-1#VpnConnections:Only one tunnel configured. Configure both (Step 1).
Mismatched Weight and Local Preference. Set them equal (Step 2).
Add a second connection on a second device (Step 3).
Advertise the same prefixes over BGP on both devices (Step 4).
High availability adds tunnels and, with a second device, a second connection, each with its own authentication secrets, so the redundant path must hold the same security posture as the primary.
Constraints: