How come nginx is only accepting 1 connection?
He Shiming
heshiming at gmail.com
Tue Jan 18 17:44:09 MSK 2011
Dear Nginx Community,
I'm trying to setup nginx with the pylons framework via uwsgi.
Nginx-0.8.54 is compiled using:
./configure --add-module=../nginx-upload-progress-module/
--prefix=/mynginx-bin --with-http_ssl_module
--add-module=../nginx_accept_language_module
And nginx.conf is:
worker_processes 1;
daemon off;
events {
worker_connections 1024;
}
http {
include mime.types;
default_type application/octet-stream;
upload_progress proxied 512m;
server {
listen 5002;
server_name localhost;
charset utf-8;
root /myproj/public;
index index.html;
client_max_body_size 2048m;
location / {
uwsgi_pass unix:/myproj/uwsgi.socket;
include uwsgi_params;
uwsgi_param SCRIPT_NAME /;
track_uploads proxied 30s;
}
location ^~ /upload_progress {
report_uploads proxied;
}
}
}
You can see there I'm trying to create the ajax file uploader. UWSGI
and pylons are the latest. UWSGI is using --paste parameter. I have to
put in "daemon off;" because this is meant for development, and I'll
have console interruption control.
I discovered that my nginx can only accept 1 connection at a time.
When a large file is uploading, all ajax calls to /upload_progress are
blocked. The requests are only answered after the upload is finished.
Opening another tab for the file upload form will also be blocked
until the upload finishes. It appears that nginx is throttling to
process only 1 request at a time.
Why does this happen? Did I somehow touched some settings to cause this?
Thanks!
--
Best regards,
He Shiming
More information about the nginx
mailing list