Skip to content

GWLB MSS clamping

0

Hello,

has anyone seen the following behaviour and can confirm that this is "as-designed"?

I have a standard setup for centralized inspection using an inspection VPC, GWLB and transitgateway. I tested by sending jumboframes through the firewall from an EC2 to another EC2(each EC2 in a different spoke VPC).

I noticed that on my Firewall I will see packets with MSS set to 8365 and I see that the final packet on the destination EC2 even shows 8341.

So something between the sender and the firewall and again between the firewall and the destination must do MSS clamping. I know TGW will clamp to 8500 but here it seems that GWLB (or GWLB endpoint) will do some additional modifications. AWS support finally told me the follwing but I would like to have this confimed:

  1. MSS clamp of 8365 on the way towards the firewall (So 8365 MSS + 64 GENEVE + 54 Traffic Mirroring = 8483 MTU. There are some variances here due to some 4-byte boundaries with VXLAN, Geneve headers, TCP/IP header lengths etc. But its sufficiently close to the expect 8500 MTU value that the TGW and GWLB supports.)
  2. Set an MSS of 8341 on the path from the firewall back to the EC2.

asked 2 years ago946 views

2 Answers
0

Yes, the behavior you're describing is indeed "as-designed" for Gateway Load Balancer (GWLB) in AWS. The Maximum Segment Size (MSS) clamping you're observing is a result of the GWLB's architecture and its interaction with other AWS networking components.

GWLB uses GENEVE encapsulation to forward traffic to the firewall appliances. This encapsulation adds overhead to the packets, which necessitates MSS clamping to ensure that the total packet size doesn't exceed the maximum transmission unit (MTU) supported by the underlying network infrastructure.

The specific MSS values you're seeing (8365 towards the firewall and 8341 from the firewall back to the EC2) are consistent with the GWLB's design:

  1. The MSS of 8365 on the way to the firewall accounts for the GENEVE header (64 bytes) and additional overhead from traffic mirroring (54 bytes). This ensures that the total packet size remains within the 8500 byte MTU limit supported by Transit Gateway.
  2. The MSS of 8341 on the return path from the firewall to the EC2 instance is slightly lower to accommodate potential variations in header sizes and ensure compatibility across different network paths.

These MSS clamping operations are performed automatically by the GWLB and its associated components to maintain network compatibility and prevent fragmentation issues. The slight variations in MSS values are due to the need to align with specific byte boundaries in the various encapsulation headers.

It's worth noting that while Transit Gateway has an MTU of 8500 bytes, the GWLB needs to account for additional overhead introduced by its own processing and encapsulation. This is why you see MSS values slightly below what you might expect based on the Transit Gateway MTU alone.

This behavior ensures that traffic can flow smoothly through the centralized inspection architecture without running into MTU-related issues, even when dealing with jumbo frames.

Sources
Experian: Centralized internet ingress using AWS Gateway Load Balancer and AWS Transit Gateway | Networking & Content Delivery
Using Gateway Load Balancer with Transit Gateway for centralized network security - Building a Scalable and Secure Multi-VPC AWS Network Infrastructure
Simplify firewall deployments using centralized inspection architecture with Gateway Load Balancer | AWS Public Sector Blog

answered 2 years ago

EXPERT

reviewed 2 years ago

EXPERT

revised 2 years ago

0

This is not in-line with what the AWS documentation (https://docs.aws.amazon.com/elasticloadbalancing/latest/gateway/gateway-load-balancers.html) says:

"The maximum transmission unit (MTU) is the size of the largest data packet that can be transmitted through the network. The Gateway Load Balancer interface MTU supports packets up to 8,500 bytes. Packets with a size larger than 8500 bytes that arrive at the Gateway Load Balancer interface are dropped.

A Gateway Load Balancer encapsulates IP traffic with a GENEVE header and forwards it to the appliance. The GENEVE encapsulation process adds 64 bytes to the original packet. Therefore, to support packets up to 8,500 bytes, ensure that the MTU setting of your appliance supports packets of at least 8,564 bytes."

So whats true now?

answered 2 years ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.