3 ms·
Not convinced that has any advantage compared to a naive approach of: - introspection at the application level: exit if memory usage goes way above usual (say
by 1996 8y ago
Not convinced that has any advantage compared to a naive approach of:
- introspection at the application level: exit if memory usage goes way above usual (say by 2x)
- management by systemd to gracefully restart the application when it exits (dependancies etc), and also monitor memory use in case the application doesn't monitor it well (say exit when 2.5x the usual)
I could be made better, but at the cost of more complexity.
- ebikelaw 8y agoI guess this would be a good way to operate dunning-kruger.com, but if you want your site to stay up this seems problematic. If you introspective application forms some belief about "usual" memory usage when it's idle an unloaded, and you suddenly shift all of your traffic from another datacenter to this one, and the heap usage on that application increases by 10x, then all your replicas will suicide.
- 1996 8y agoIf the memory usage can increase 10x while this is not reflected in the assumptions, both the measurements and the assumptions are flawed To give more context: I run many copies of a daemon with known memory leaks, on machines each with a load close to 0.7 and about 200M of free ram left. I consider that an heavy load. This approach restarts one of the copies of the daemon when its own leaks become dangerous to the rest of the system. It is not perfect, but good enough when the numbers are measured at peak. The 200Mb free RAM are all the extra leeway I care to leave.