Memory use flares up sharply, how to troubleshoot?
gthb
nginx-forum at nginx.us
Tue Jul 22 14:51:43 UTC 2014
Hi,
here's a minimal configuration where I can reproduce this:
error_log debug.log debug;
events {
worker_connections 1024;
}
http {
uwsgi_buffers 64 8k;
upstream nginx-test.uwsgi {
server 10.0.0.7:13003;
least_conn;
}
server {
listen 8080;
server_name nginx-test.com;
location /api/ {
include uwsgi_params;
uwsgi_pass nginx-test.uwsgi;
}
}
}
Here's a debug log covering server start, a single request that exhibits the
problem, and server shutdown:
http://filebin.ca/1UClE4zzhfZe/debug.log.gz
Everything goes OK for a while, just a few stray mallocs, and then maybe
half a minute into the request (the time varies), after maybe 20-25MB have
been transferred, the flood of mallocs starts:
$ grep malloc: debug.log | cut -d ' ' -f 2 | uniq -c
4 14:34:51
1 14:34:52
3 14:34:56
1 14:34:59
1 14:35:03
2 14:35:12
1216 14:35:27
1135 14:35:28
2144 14:35:29
1996 14:35:30
520 14:35:31
(That last second of mallocs is only smaller because I stopped the client,
so the request was aborted)
I hope that debug log turns up something informative --- and thank you again
for your time on this.
Cheers,
Gulli
Posted at Nginx Forum: http://forum.nginx.org/read.php?2,251964,251988#msg-251988
More information about the nginx
mailing list