NGINX PROXY 0000 1204 0000 0000 0000 0300 0000 8000

nginx上次更新之后,我所有的页面都得到了:

0000 1204 0000 0000 0000 0300 0000 8000 0400 0000 0000 0500 ffff ff00 0004 0800 0000 0000 7fff 0000 0000 0807 0000 0000 0000 0000 0000 0000 01 

有一个带有jails的FreeBSD / 10.2-RELEASE-p17盒子。

  1. 10.10.10.1:80:Apache / 2.4.20 – 仅作为内部networking – 通用的虚拟主机

  2. XX.XX.XX.XX:80:nginx / 1.10.0作为代理和负载均衡器到Apache24 – 这是公共的

内部networking工作(apache)testing所有文件:

 curl -I --header 'Host: myserver.com' http://10.10.10.1:80/ HTTP/1.1 200 OK Date: Fri, 20 May 2016 11:23:08 GMT Server: Apache Set-Cookie: _icl_current_language=en; expires=Sat, 21-May-2016 11:23:08 GMT; Max-Age=86400; path=/ Set-Cookie: _icl_current_language=en; expires=Sat, 21-May-2016 11:23:08 GMT; Max-Age=86400; path=/ Content-Type: text/html; charset=UTF-8 

内部或外部networking(nginx)的testing在所有文件上失败:

 curl -I --header 'Host: myserver.com' http://XX.XX.XX.XX:80/ ▒▒ 

它正在发生所有的configuration; 此服务器不涉及SSL。

 server { listen 80 ; server_name myserver.com expires off; location / { proxy_no_cache 1; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $remote_addr; proxy_set_header Host $host; proxy_set_header X-Forwarded-Proto $scheme; proxy_pass http://10.10.10.1:80/; } } 

最初我以为它可能与http / 2连接,但我没有在这个主机configuration上使用它。 Nginx有多个主机,一些有其他nginx http / 2主机的http / 2连接 – 这工作正常。 在nginx上为其他主机代理安装了无效的SSL – 但它工作。

这是NGINX -v

 nginx version: nginx/1.10.0 built with OpenSSL 1.0.2h 3 May 2016 TLS SNI support enabled configure arguments: --prefix=/usr/local/etc/nginx --with-cc-opt='-I /usr/local/include' --with-ld-opt='-L /usr/local/lib' --conf-path=/usr/local/etc/nginx/nginx.conf --sbin-path=/usr/local/sbin/nginx --pid-path=/var/run/nginx.pid --error-log-path=/var/log/nginx-error.log --user=www --group=www --modules-path=/usr/local/libexec/nginx --with-ipv6 --with-google_perftools_module --http-client-body-temp-path=/var/tmp/nginx/client_body_temp --http-fastcgi-temp-path=/var/tmp/nginx/fastcgi_temp --http-proxy-temp-path=/var/tmp/nginx/proxy_temp --http-scgi-temp-path=/var/tmp/nginx/scgi_temp --http-uwsgi-temp-path=/var/tmp/nginx/uwsgi_temp --http-log-path=/var/log/nginx-access.log --add-module=/wrkdirs/usr/ports/www/nginx/work/nginx_accept_language_module-2f69842 --with-http_addition_module --add-module=/wrkdirs/usr/ports/www/nginx/work/nginx-auth-ldap-8517bb0 --add-module=/wrkdirs/usr/ports/www/nginx/work/ngx_http_auth_pam_module-1.2 --add-module=/wrkdirs/usr/ports/www/nginx/work/ngx_cache_purge-2.3 --add-dynamic-module=/wrkdirs/usr/ports/www/nginx/work/headers-more-nginx-module-f5559ec --with-http_dav_module --add-module=/wrkdirs/usr/ports/www/nginx/work/nginx-http-footer-filter-1.2.2 --with-http_geoip_module=dynamic --with-http_gzip_static_module --with-http_gunzip_module --with-http_image_filter_module=dynamic --add-module=/wrkdirs/usr/ports/www/nginx/work/nginx-notice-3c95966 --with-http_perl_module=dynamic --with-http_realip_module --with-http_slice_module --with-http_stub_status_module --with-http_sub_module --with-http_xslt_module=dynamic --add-module=/wrkdirs/usr/ports/www/nginx/work/ngx_devel_kit-0.2.19 --add-module=/wrkdirs/usr/ports/www/nginx/work/memc-nginx-module-0.16 --with-pcre --add-module=/wrkdirs/usr/ports/www/nginx/work/xss-nginx-module-0.04 --with-http_v2_module --with-stream=dynamic --with-stream_ssl_module --with-threads --with-http_ssl_module --add-module=/wrkdirs/usr/ports/www/nginx/work/iconv-nginx-module-0.10 

这只发生在后面的Apache服务器上。 同样的configuration在过去的6年里工作; 这发生在nginx升级之后。

任何想法可能会发生什么? 错误?

hex转储包含HTTP / 2 SETTINGS和WINDOW_UPDATE数据。 看看nghttp -n -vvv '<host>' --hexdump 。 最后一位0000 0807 0000 0000 0000 0000 0000 0000 01表示错误,请参阅rfc7540 。 不确定,但看起来像一个错误代码GOAWAY框架结束。

你的curl讲http / 1.1到一个nginx的http / 2端口 – 没有正确的升级语言来接收http2,可能不是针对nghttp2编译的。 Nginx在它的部分没有在http / 2启用的端口上执行http / 1.1(见nginx bugtrac中的#816 )。 所以你的卷发版本和nginx版本不能互相讲话。 您可以search是否意外地在端口80上启用了http2,或者在代理服务器的某个块中代理http2到端口80。