I administer 10+ Moodle instances that share a single Ubuntu server. The server is hosted in Microsoft's Azure, and has 4 CPUs and 7GB RAM. The OS is Ubuntu Server 16.04.6 LTS, with PHP 7.0.33 and MySQL 5.7.25 on Apache.
One of the Moodles (currently running Moodle 3.5.3+) is causing load issues when it is running backups. This Moodle has a large number of users (8,000+), although only about half of them would be current (i.e. actually enrolled in a course) at any one time. The main user activity is quizzes - users are encouraged to attempt the quizzes in their subject multiple times before attempting the exam.
The issue we see is that when this Moodle is running backups, MySQL starts taking all of one CPU. We have verified that it is this Moodle's backups that cause this issue, because when we deactivated them one night, that night the issue did not occur. We also can see that each course backup takes more than half an hour - this is obvious from the backup file names, which have a timestamp.
This load on the database causes all of the Moodles to have degraded performance. When the problem Moodle's backups were running from 03:30 to 13:00 or 14:00, once they finished we saw an improvement in responsiveness across the board. Now the problem Moodle's backups are taking 16 or 17 hours every day.
It seems as though MySQL is not multi-core-aware. Either that, or it needs to be configured to use multiple cores.
Alternatively, are there settings within the Moodle that might affect the backup load like this? A full MySQL dump of this Moodle database is over 5GB - is it just that there is so much to back up that we're seeing this issue?
Any other suggestions for dealing with this?