#I have a Django application where I have uwsgi as a web server for deployment.

18 messages · Page 1 of 1 (latest)

exotic scroll
#

Hi team,
I have a django application using sqlite3 and Redis as DB, uwsgi for deployment. They are all containerized with kubernetes.
Getting following error intermittently:
DAMN ! worker 4 (pid: 43510) died, killed by signal 9 :( trying respawn ... Respawned uWSGI worker 4 (new pid: 44432)

It seems unix is killing(SIGKILL signal)
How to proceed further?

Following is my uwsgi configs:
[uwsgi] http = :8000 wsgi-file = app_name/wsgi_production.py processes = 8 threads = 4 listen = 128 stats = 127.0.0.1:9191 add-header = Connection: close harakiri-verbose = true py-callos-afterfork = true reload-on-rss = 1024 worker-reload-mercy = 60

Getting lot of production issues due to this

tall patrol
#

My first guess anytime I see my apps getting regularly killed with a signal 9, is that the OS is running out of memory.

exotic scroll
#

Any way to validate that? It only happens with one worker at a time(out of 8 active)

hasty ginkgo
#

In my experience, it's best to force worker reload every ~500 requests...

#

It's very possible something is leaking memory.

exotic scroll
#

ok...Also I am thinking of inducing garbage_collection here!!

exotic scroll
#

Any way to configure uwsgi configs using env variables? or maybe using settings.py?

hasty ginkgo
exotic scroll
#

It banned mine also for some time.. but now it's up

hasty ginkgo
#

There's a section called environment variables.

#

It probably thought I was trying to read them as it was anchored 😆

exotic scroll
exotic scroll
hasty ginkgo
#

Not AFAIK. uWSGI is not Django-specific.

#

It can run Flask, Bottle, etc.