1

I have deployed my Django application using nginx + uwsgi. I have also implemented micro caching and made other changes by following this article (Nginx 10k concurrent connections).

Now I am using jMeter and testing for 1000 concurrent requests. Earlier, the server used to throw 502 after 70-80 requests but currently it's serving all 1000 requests with out fail.

Problems are:

  1. The average response time is 18 secs. It starts with 1.9 secs and goes to 18.
  2. I am using 8 core server and server load never reaches even 20%. htop screenshot during load test
  3. uwsgitop shows that 13 uwsgi workers remains in idle state. only 2-3 workers are serving all 1000 requests. uwsgihtop screenshot during load test

Why nginx / uwsgi is not using server's maximum capacity to serve requests. How can I make server to use all uwsgi workers so that I can reduce my response time from 18 sec to 1-2 secs.

0 Answers0