Decreasing RAM Usage by 40% Using jemalloc with Python & Celery
Blog post from Zapier
At Zapier, the team faced challenges with high RAM usage and swap memory when running hundreds of Python and Celery instances to handle extensive tasks, which impeded hardware upgrades due to the lack of faster instance store support over EBS. The memory issue, suspected to be caused by fragmentation, led them to experiment with jemalloc, a memory allocator known for handling fragmentation effectively, as seen in Redis. After implementing jemalloc versions 3.5.1 and 5.0.1, they observed a significant reduction in RAM usage, with a 30% decrease using jemalloc 3.5.1 and a 40% decrease using jemalloc 5.0.1, compared to the original setup. Although the precise reasons for this improvement are unclear, the results suggest that jemalloc's ability to reclaim fragmented memory contributed to the enhanced efficiency of their systems.
No tracked trend matches for this post yet.