- Newest
- Most votes
- Most comments
When a Network Load Balancer (NLB) or Gateway Load Balancer (GWLB) has targets that become unhealthy, there are specific behaviors that govern how traffic is handled.
In your case, there are a few key points to understand:
-
Fail-open mode: By default, when all targets become unhealthy, the load balancer enters "fail-open" mode, where it routes traffic to all registered targets regardless of health status. However, this shouldn't be happening in your case since you still have one healthy firewall.
-
Minimum healthy targets threshold: There's a configurable setting called "unhealthy_state_routing.minimum_healthy_targets" that determines when the load balancer should enter fail-open mode. If the number or percentage of healthy targets falls below this threshold, the load balancer will route traffic to all targets, including unhealthy ones. This could explain why your unhealthy firewall is still receiving traffic.
-
Connection termination setting: For existing connections, the load balancer has a "connection termination" setting. If disabled (which is the default), existing connections to an unhealthy target will be kept active. However, this shouldn't affect new TCP SYN packets that you're observing.
-
Source IP stickiness: If you have source IP stickiness enabled, the load balancer might continue routing traffic from specific source IPs to the same target, even if it becomes unhealthy, for a short period.
To resolve this issue:
-
Check your target group attributes, specifically the "unhealthy_state_routing.minimum_healthy_targets" setting. You might need to adjust this to ensure it doesn't trigger fail-open mode with just one unhealthy firewall.
-
Verify if source IP stickiness is enabled and consider its impact on your traffic distribution.
-
Ensure your health check settings are correctly configured to accurately detect unhealthy targets.
-
Consider enabling the "connection termination" setting if you want to immediately terminate connections to targets that become unhealthy.
These adjustments should help ensure that new traffic is only routed to your healthy firewall when one becomes unhealthy.
Sources
unhealthy host in network load balancer | AWS re:Post
Target Group - Only send traffic to healthy nodes | AWS re:Post
Network Load Balancer Stickiness Timeout with Unhealthy Nodes | AWS re:Post
Update the target group health settings for your Network Load Balancer - Elastic Load Balancing
answered a year ago
Relevant content
asked 4 years ago
asked a year ago
asked 4 years ago
- AWS OFFICIALUpdated 7 months ago

I’m not hitting, Fail-open mode I have 1 healthy and 1 unhealthy target, I have waited 10+ minutes to make sure this is the correct state. I’ve crossed the Minimum healthy targets threshold. Connection termination setting, I’m sending new tcp sessions on new ports with a fresh sequence number. Source IP stickiness, it’s sending some traffic to the healthy and some traffic to the unhealthy, these again are NEW sessions