Issue MYSQL Memory spike during backup

thinkjarvis

Basic Pleskian
Server operating system version
Ubuntu 24.04.3 LTS
Plesk version and microupdate number
Plesk Obsidian Version 18.0.72 Update #2
We are seeing a consistent problem on one of our plesk servers.

When the scheduled backup runs (Set to save locally, databases only). It causes Maria DB/MYSQL memory consumption to jump by several gb. This memory is never flushed or purged.

Over a week - This memory use creeps until mysql and system memory hits over 90% of the ram total. This means that the PHP FPM processes no longer have enough available memory to run - Causing mariadb to crash.

We have had to schedule a nightly restart of mariadb via cron job to ensure that the memory doesnt continually fill.

I think this is a bug in Plesk. Any ideas on what might cause this behaviour or how I can release the alocated memory after a backup? Or just prevent the ram consumption completely?

The spike is the backup running, the sudden drop is our scheduled mariaDB restart.

1757493495659.png
 
MariaDB has a dedicated documentation page on memory usage and how to profile it, which might be a useful read.

Other interesting reads on MaraiDB memory usage are:
 
@Kaspar jemalloc looks interesting as a solution to the problem - If it can manage the memory pool more efficiently then we may have a winner here.

I am going to speak with our managed hosting providers to see if they can impliment on one of our servers as a test.
 
Back
Top