Open kosmos opened 4 days ago
Hi @kosmos, thanks for filing an issue. Can I just double-check that you're using jemalloc
in your configuration? Doing so is required for the cache_autotuning
option.
@anoadragon453 I'm using the official docker image, and this feature (jemalloc
) is enabled by default.
@kosmos Did you upgrade from 1.1130 before being on 1.114.0? I don't see any changes that are particularly related to caches in 1.114.0.
Around the time of the memory ballooning, are you seeing lots of initial syncs at once? Those requests are known to be memory intensive, especially for users with a large amount of rooms.
Do you have monitoring set up for your Synapse instance? If so, could you have a look at the Caches -> Cache Size
graph around the time of the memory ballooning to see what cache might be overinflating? I'm also happy to poke through your Grafana metrics if you can make them privately or publicly available. Feel free to DM me at @andrewm:element.io
if you'd like to share them via that route.
Description
I have the following synchrotron worker configuration:
And the following cache settings for this worker:
All other worker types work without problems, but it is a memory leak in synchrotrons, which leads to the exhaustion of all memory.
It seems that the
cache_autotuning
settings are not working. The environment variablePYTHONMALLOC=malloc
is set at the operating system level.According to my impressions, the problem became relevant after updating to 1.114 of Synapse and remains relevant in 1.116.
Steps to reproduce
To reproduce the problem, you need a homeserver with a heavy load and dedicated synchrotron workers.
Homeserver
Synapse 1.116.0
Synapse Version
Synapse 1.116.0
Installation Method
Docker (matrixdotorg/synapse)
Database
PostgreSQL
Workers
Multiple workers
Platform
-
Configuration
No response
Relevant log output
Anything else that would be useful to know?
No response