By default, NSX Advanced Load Balancer appends additional HTTP headers (Host, User-Agent and Accept) into HTTP health monitor requests.
Header |
Values |
---|---|
User-Agent |
avi/1.0\r\n |
Host |
<hostname>\r\n |
Accept |
*/*;\r\n\r\n |
You can prevent from adding additional Host header. Use Exact Request option on NSX Advanced Load Balancer UI or use_exact_request flag in NSX Advanced Load Balancer CLI for a health monitor instructs NSX Advanced Load Balancer to pass the exact HTTP request string as specified by NSX Advanced Load Balancer admin (user), without any automatic insertion of the additional HTTP headers. This indicates that user is now responsible for adding the appropriate headers to the HTTP client request field.
Configuration from NSX Advanced Load Balancer CLI
Login to NSX Advanced Load Balancer CLI, and use configure healthmonitor System-HTTP command to change the value of the flag exact-http-request
.
[admin:10-1-1-1]: > configure healthmonitor System-HTTP [admin:10-1-1-1]: healthmonitor> http_monitor [admin:10-1-1-1]: healthmonitor:http_monitor> http_request [admin:10-1-1-1]: healthmonitor:http_monitor> http_request "HEAD / HTTP/1.0\r\n\r\n" Overwriting the previously entered value for http_request [admin:10-1-1-1]: healthmonitor:http_monitor> exact_http_request Overwriting the previously entered value for exact_http_request [admin:10-1-1-1]: healthmonitor:http_monitor> [admin:10-1-1-1]: healthmonitor:http_monitor> save [admin:10-1-1-1]: healthmonitor> save
Configuration from NSX Advanced Load Balancer UI
Navigate to
.Choose the desired HTTP health monitor and click edit icon.
Select the check box for Use Exact Request.
Click Save.