ingress-nginx: upstream timed out (110: Operation timed out) while ..
Error: upstream timed out (110: Operation timed out) while connecting to upstream. and upstream timed out (110: Operation timed out) while reading response header from upstream
It happens randomly (every 2-3 minutes or so) for all applications at the same time. I could resolve the timeout problem using annotations.
But why is it inconsistent? Sometimes it takes up to 2-3 minutes to get response from servers. Some of my servers are simple hello-world applications with “nginx” container images.
Environment:
AKS cluster with 1 master and 1 worker node (2 CPU + 4 GB memory).
Ubuntu 18.04.6 LTS
**Tested** with both:
NGINX Controller v1.5.1, helm version 4.4.4
NGINX controller v1.2.1, helm version 4.1.3.
Have plenty of memory and CPU available. Increasing number of applications replicas does not solve my issue.
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 19 (8 by maintainers)
thank you for the clue. @amodsachintha . It resolved my problem.
@frixou89 in case your problem still exists. kindly refer to https://github.com/terraform-aws-modules/terraform-aws-eks/blob/master/docs/network_connectivity.md#security-groups
add this block to your EKS terraform module:
this is to allow communication between nodes in the cluster. the reason ingress throwing “Operation timed out” is because internally it proxies the request from 1 node to another node.
This was an issue with the security group that controlled inter-node communications in the EKS terraform module.
Thanks for your reply! I’m not sure I remember what the issue was. This is what I have right now in a working setup for
node_security_group_additional_rules.Thanks @crossRT that was also my problem. In my case this issue was well hidden because nginx would timeout trying to connect node to node, and then use the current node to deliver the app. I found the problem originally by tailing the logs of the ingress-nginx namespace and saw the timeout on every request.
+1 we are facing the same problem here, a lot of
upstream timed out (110: Operation timed out) while connecting to upstream.andupstream timed out (110: Operation timed out) while reading response header from upstreamtill 10h ago.@fred-aa with annotations you put?