You’re looking at the request header while you should be looking at the response header. You’re right in that the request header says “Connection: keep-alive”, i.e. the browser would like to keep the connection alive, but the response header shows that the server refuses this with “Connection: close”. You should probably take another look at your nginx configuration.
I’m using nginx. I’ll post the settings in another reply. Thanks.
[hr]
Robzilla, bastester, thanks.
Robzilla, I see your point about the response and I see the difference between the two tests. What’s strange is that the same nginx configuration below yielded an A and an F on the other. Both systems use varnish-nginx (same settings). Is it possible that it’s on the load balancer settings? (The A does not have any load balancer, the F has).
Yes, your users talk to your load balancer listening on port 80/443, which in turn talks to nginx via a connection separate from the first. Because the load balancer manages all connections with the public, nginx’s keepalive setting never enters the picture.
In fact, in a nginx+Varnish set-up, I would expect that Varnish handles keepalives. Whichever application faces the public.