Hello again!  Today’s topic is memory limits.

We were hoping to use limit-as to limit the total addressable memory and 
reload-on-rss (or evil-reload-on-rss) to catch gradual memory leaks.

We’re in our usual setup:  an emperor with chrooted vassals + workers.

We found two problems – problems for us, they may not be problems for uWSGI:

1) limit-as works, but it leaves the worker in a crashed state, where it just 
hits a MemoryError for every request.  Unfortunately, it does not die and free 
up memory.  So, the feature request would be, some kind of monitor that kills 
workers when they’ve hit a memory limit.  The next problem is related however:

2) reload-on-rss does not work for us.  We think it’s because our chroot 
environment does not expose /proc, so the master process cannot tell how much 
memory the worker is using.  By way of evidence, we tried using the 
memory-report flag to add memory info to the logs, and they would always show 
0virt and 0 rss used. The only solution we can think of is to give the job of 
killing misbehaving workers to the emperor, instead of to the master.


Possibly nobody else is running vassals in such a crippled chroot environment, 
so I don’t know whether these would be desirable changes for uWSGI, but I 
thought I should share our experiences, in case it’s of interest...

rgds,
Harry


-- 
Harry Percival
Developer
[email protected]

PythonAnywhere - a fully browser-based Python development and hosting 
environment
<http://www.pythonanywhere.com/>

PythonAnywhere LLP
17a Clerkenwell Road, London EC1M 5RD, UK
VAT No.: GB 893 5643 79
Registered in England and Wales as company number OC378414.
Registered address: 28 Ely Place, 3rd Floor, London EC1N 6TD, UK
_______________________________________________
uWSGI mailing list
[email protected]
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi

Reply via email to