websocket connection seems to cause nginx to not reload

nanaya me at nanaya.pro
Tue Apr 16 03:14:42 UTC 2019


Hi,

On Tue, Apr 16, 2019, at 07:14, Andrea Y Ma wrote:
> Seeing nginx not picking up changes to its configuration. Running 
> `nginx -t` does not reveal any errors and no errors generated when 
> running `nginx -s reload`. However nginx access logs show that the old 
> IPs from the previous configuration are still being served. Upon closer 
> inspection seeing that nginx defunct process are occurring each time a 
> `nginx -s reload` is run.
> Also seeing that it seems related to a websocket application as when 
> that websocket application is stopped, then the nginx -s reload 
> completes successfully.
> Andrea Ma
> 

As websocket connections are persistent, the old processes will stay up until the last connection disconnects. It also applies to normal http (for example when someone is downloading/uploading large file) but it's way more visible with websocket.

(or at least that's how I understand it)


More information about the nginx mailing list