# Websockets proxy "Broken pipe"

**URL:** <https://www.ruby-forum.com/t/websockets-proxy-broken-pipe/243305>\
**Category:** NGINX\
**Created:** [September 9, 2015, 1:09pm UTC](https://www.ruby-forum.com/t/websockets-proxy-broken-pipe/243305 "2015-09-09T13:09:59Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Rafa\_F](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/958977/32.png) [@Rafa\_F](https://www.ruby-forum.com/u/Rafa_F)\
**Post date:** [September 9, 2015, 1:09pm UTC](https://www.ruby-forum.com/t/websockets-proxy-broken-pipe/243305/1 "2015-09-09T13:09:59Z")

</div>

I have a problem with nginx and websockets proxy.

Here is the message I receive:

[error] 20999#0: \*1997296 send() failed (32: Broken pipe) while proxying  
upgraded connection, client: 10.0.25.47, server: [example.com](http://example.com), request:  
“GET  
/xmpp/ HTTP/1.1”, upstream: “[http://192.168.122.8:5280/xmpp/](http://192.168.122.8:5280/xmpp/)”, host:  
“[example.com](http://example.com)”

Here is my config:

```
    location /xmpp {
            proxy_pass http://192.168.122.8:5280;
            proxy_http_version 1.1;
            proxy_set_header Upgrade $http_upgrade;
            proxy_set_header Connection "upgrade";
    }

```

When ejabberd has big history log, nginx returns error message.

nginx -V  
nginx version: nginx/1.4.6 (Ubuntu)  
built by gcc 4.8.2 (Ubuntu 4.8.2-19ubuntu1)  
TLS SNI support enabled  
configure arguments: --with-cc-opt=‘-g -O2 -fstack-protector  
–param=ssp-buffer-size=4 -Wformat -Werror=format-security  
-D\_FORTIFY\_SOURCE=2’ --with-ld-opt=‘-Wl,-Bsymbolic-functions  
-Wl,-z,relro’  
–prefix=/usr/share/nginx --conf-path=/etc/nginx/nginx.conf  
–http-log-path=/var/log/nginx/access.log  
–error-log-path=/var/log/nginx/error.log  
–lock-path=/var/lock/nginx.lock  
–pid-path=/run/nginx.pid  
–http-client-body-temp-path=/var/lib/nginx/body  
–http-fastcgi-temp-path=/var/lib/nginx/fastcgi  
–http-proxy-temp-path=/var/lib/nginx/proxy  
–http-scgi-temp-path=/var/lib/nginx/scgi  
–http-uwsgi-temp-path=/var/lib/nginx/uwsgi --with-debug --with-pcre-jit  
–with-ipv6 --with-http\_ssl\_module --with-http\_stub\_status\_module  
–with-http\_realip\_module --with-http\_addition\_module  
–with-http\_dav\_module  
–with-http\_geoip\_module --with-http\_gzip\_static\_module  
–with-http\_image\_filter\_module --with-http\_spdy\_module  
–with-http\_sub\_module --with-http\_xslt\_module --with-mail  
–with-mail\_ssl\_module

Posted at Nginx Forum:

> **[Websockets proxy "Broken pipe"](https://forum.nginx.org/read.php?2,261527,261527#msg-261527)**
>
> I have a problem with nginx and websockets proxy. Here is the message I receive: \[error\] 20999#0: \*1997296 send() failed (32: Broken pipe) while proxying upgraded connection, client: 10.0.25.47, server: example.com, request: "GET /xmpp/...
