问题
My uWSGI logs are full of entries like this for every request:
localhost [pid: 4029|app: 0|req: 1/1] 127.0.0.1 () {48 vars in 906 bytes} [Wed Mar 23 18:35:38 2016] GET / => generated 94847 bytes in 1137 msecs (HTTP/1.1 200) 4 headers in 224 bytes (1 switches on core 0)
I'm not sure if it's uWSGI spamming them or Django. How can I disable the request logging?
回答1:
What does your uwsgi.ini
look like? That's where you'd want to disable logging.
Set: disable-logging=True
Here's the docs:
http://uwsgi-docs.readthedocs.org/en/latest/Options.html#disable-logging
回答2:
Or from the console with:
uwsgi --disable-logging
来源:https://stackoverflow.com/questions/36186324/how-to-disable-request-logging-in-django-and-uwsgi