Question:
We have external nginx proxy. And we tested our site from different ips. The whole http trafic send to nginx proxy and proxy send trafic to kubernetes NodePort(we do not use ingress). Proxy has upstream that point to 2 ips kube master. And we send about 300 requests to proxy in seccond and in logs proxy i see next messages: “upstream prematurely closed connection while reading response header from upstream”.
Can be that kube iptables blocked trafic from nginx proxy ?
Where i can see logs the my problem ?
The problem is (most often) related to timeouts. Especially if your application on the backend isn’t able to handle requests in an orderly fashion. I’d first increase your timeouts using something as simple as: