Tuning performance on the MySQL or MariaDB server will provide a significant performance improvement. Because MySQL's default setting is not good if your site has many visitors. Sometimes it can cause very high CPU load on the busy server and the most annoying is Error Establishing a Database Connection, as often happens in WordPress based site.
I will give you a complete performance tweaks on your database server.
Note: This gig specifically for Linux servers only, including CentOS, Debian and Ubuntu. You must send me the root login details, passwords, IP addresses and active SSH ports.
MySQL/MariaDB Performance Tuning
Best performance tuning for your MySQL server config. Better performance and consistency.