M ...
Not sure that anyone's comparison stats would really help you or not - unless your hardware is same or dang close ... and that could be a very deep and detailed pursuit. Hmmmm .... I don't like 'DEEP rabbit holes' myself.
Having said that ...
Serving the code and also hosting the DB.
The cli scripts take apache out of the loop ... it's just PHP and the dB then.
In your top screen snap noticed the first line ... I take it that's when server was running auto backups?
user mysql ... virt memory (SWAP Space?) is 1.5 Gig. 130% of CPU (Ouch!)
Nothing runs well using SWAP ... especially DB's.
There are two other mysql processes using 57 and 55%
A server that is an 'all in one' ... Apache/Code + DB server and DB for moodle
*requires* tweaking ... balancing act between however you are running apache (mem/proceeses) and the DB server (MariaDB).
According to a Percona article/blog posting db runs best when using 80% of the memory
of the server it's on, but don't think that's possible in an 'all in one'. Best I've ever gotten was a little over 60%.
Suggest installing and running MySQLTuner.
https://github.com/major/MySQLTuner-perl
Séverin has already said that ... I'll +20 that suggestion!
Backups ... they are gonna be heavy IF there are modules contained in courses
that are heavey processing anyway ... like quiz.
What's preferences for backups/autobackups? ie, hitories, grades, all users, etc.
That's a factor ... isn't it?
Are you autobacking up courses you don't need to? Like courses that are hidden, test courses, etc.
If I were you ...
**** Since it's a VM, if one could, bump memory for it ... 32Gig to 48Gig - even a little might be enough if your VM server is 'crowded'.
**** Do run tuner ... before bumping mem and after bumping mem.
My 2 cents!
'spirit of sharing', Ken