What is the PROXY protocol?
IntermediateConceptLoad Balancers, Proxies & CDNs
Answer
A small header (v1 text or v2 binary) prepended by an L4 proxy to the TCP stream carrying the original client IP and port, since the backend only sees the proxy's address. The backend must be configured to expect it, or every connection will fail.
nginx: listen 80 proxy_protocol;, then real_ip_header proxy_protocol;. NLB can enable it per target group when preserving source IP is not possible.
More on Load Balancers, Proxies & CDNs
What is a load balancer and why do we use one?BeginnerWhat is the difference between L4 and L7 load balancing?IntermediateCompare ALB, NLB, GWLB and Classic Load Balancer in AWS.IntermediateWhat load-balancing algorithms are common?BeginnerWhat are health checks and how should they be designed?AdvancedWhat is connection draining (deregistration delay)?Intermediate