-
Notifications
You must be signed in to change notification settings - Fork 110
Description
I'm using the following version of Nginx.
nginx version: nginx/1.14.0
built by gcc 4.8.5 20150623 (Red Hat 4.8.5-36) (GCC)
built with OpenSSL 1.0.2k-fips 26 Jan 2017
TLS SNI support enabled
configure arguments: --prefix=/opt/nginx --with-http_ssl_module --with-http_v2_module --with-http_realip_module --with-http_gunzip_module --with-http_gzip_static_module --with-http_auth_request_module --with-http_stub_status_module --with-threads --with-stream --with-stream_ssl_module --add-module=/tmp/ngx_devel_kit-0.3.0 --add-module=/tmp/lua-nginx-module-0.10.9rc7
I have defined four virtual servers in http config block. One virtual server is defined with listen 443 ssl;, while three other virtual servers are defined with listen 443 ssl http2;. The lua-nginx-module is used in the server without http2 configured to handle file upload. The code is as follows.
local req_socket = ngx.req.socket
local sock, err = req_socket()
if not sock then
return nil, err
end
Strange thing is the error.log reports that http v2 is not supported yet. But the http2 is not even configured in this virtual server. The error log is as below.
2019/04/29 15:26:19 [error] 22281#22281: *6512 lua entry thread aborted: runtime error: /opt/nginx/co
nf/lua/resty/upload.lua:61: http v2 not supported yet
stack traceback:
coroutine 0:
[C]: in function 'req_socket'
/opt/nginx/conf/lua/resty/upload.lua:61: in function 'new'
It looks like the http2 configuration exists beyond the virtual server in which it's configured, like somehow it becomes a global thing.
After I delete the http2 in all three other virtual servers, the error.log stops reporting the error mentioned above.
I don't know what make this happen. Is it a bug or something wrong with my configuration?