# Connection refused problem

**URL:** <https://www.ruby-forum.com/t/connection-refused-problem/192319>\
**Category:** NGINX\
**Created:** [July 28, 2010, 5:15am UTC](https://www.ruby-forum.com/t/connection-refused-problem/192319 "2010-07-28T05:15:39Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![wangbin579](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/w/bc79bd/32.png) [@wangbin579](https://www.ruby-forum.com/u/wangbin579)\
**Post date:** [July 28, 2010, 5:15am UTC](https://www.ruby-forum.com/t/connection-refused-problem/192319/1 "2010-07-28T05:15:39Z")

</div>

all servers are running and nginx has the following error log every once  
in a while.

2010/07/27 08:37:57 [error] 1948#0: \*429632943 connect() failed (111:  
Connection refused) while connecting to upstream, client:  
125.45.229.167, server: xx.xxx.xxx, request: “GET xxxx HTTP/1.1”,  
upstream: “server://xx.xxx.xxx.xxx:xxxxx”, host: “xxx.xxx.xxx”,  
referrer: “xxx”

Is the listen queue full ?what causes the above problem?  
thx

Posted at Nginx Forum:

> **[Connection refused problem](https://forum.nginx.org/read.php?2,113710,113710#msg-113710)**
>
> all servers are running and nginx has the following error log every once in a while. 2010/07/27 08:37:57 \[error\] 1948#0: \*429632943 connect() failed (111: Connection refused) while connecting to upstream, client: 125.45.229.167, server: xx.xxx.xxx,...

---

<div class="post-metadata">

**Author:** ![wangbin579](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/w/bc79bd/32.png) [@wangbin579](https://www.ruby-forum.com/u/wangbin579)\
**Post date:** [July 28, 2010, 5:23am UTC](https://www.ruby-forum.com/t/connection-refused-problem/192319/2 "2010-07-28T05:23:52Z")

</div>

ur upstream is refusing the connection as described in the error log.  
have you checked ur upstream logs? could be multiple things, starting  
from server configurations to webserver config. check to make sure ur  
not hitting ur max connection on the upstream httpd, paste an output  
of ‘dmesg’, if ur running iptables or any other firewall makes sure to  
check the logs and rules and check the system to confirm that u are  
not running out of sockets to be used by the upstream httpd as well as  
system file descriptors “ulimit -a”

## if u want you can paste an output and i can help troubleshoot cheers

Payam Tarverdyan Chychi  
Network Security Specialist / Network Engineer
