MariaDB configuration settings

MariaDB configuration settings

by Yong Ra -
Number of replies: 4
Hi everyone,

I just upgraded the MariaDB to version 10.3 so I can upgrade the Moodle to 3.9. When It is at 3.8 running MariaDB 5.5, I placed some recommended settings in the my.cnf file for InnoDB settings.

When I upgraded the MariaDB, those settings were causing error and I had to comment them out.

Is there any recommended MariaDB configuration settings I need to add instead of running it on a default setting?


Thank you,
Average of ratings: -
In reply to Yong Ra

Re: MariaDB configuration settings

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers
My guru, Ken, has warned me about sharing my.cnf settings because they need to be personalized for every different server. However, I will at least share my my.cnf file, which is working on my MariaDB 10.2.31 Moodle 3.9 system. Be careful to not treat my settings as "the best." In my my.cnf file, you will see that I tried to highlight where all these settings came from. Fine-tuning a database seems to be somewhat of an art, and not a science. Well, here's my file.

If you find any of my settings to be incorrect, I would like to know.  (Thanks.)


In reply to Rick Jerz

Re: MariaDB configuration settings

by Ken Task -
Picture of Particularly helpful Moodlers

Please ... 'guru'???!!! More like 'guessed right 3 times in a row'!

Anyhooo ... 'rattled' my tree ... so a response ... kinda.

Chuckle ... see the config file is well commented ... even 'who to blame'? (not really).

The only reason for suggesting not sharing ... OP we do now know, copies and paste without checking docs for DB servers.

Some settings I had for MySQL 5.6 no longer needed in 5.7 ... and beyond.

Do have a suggestion for ya Rick (OP also if OP doesn't have 'command line avoidance syndrome') ... install MySQL Tuner on that server and let's see what it recommends. ;)

'SoS', Ken


In reply to Ken Task

Re: MariaDB configuration settings

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers
Yep, I need to still learn how to install MySQL Tuner, guru Ken! 😀

What my commenting shows is that I had to dig around quite a bit to determine what needed to go into this my.cnf file.

Actually, the way that I experimented was to make some changes and then run that "perspective.php" file.  I am sure that MySQL Tuner would be better.  I really haven't touched this my.cnf file for a few years.
In reply to Yong Ra

Re: MariaDB configuration settings

by Alain Raap -
Picture of Particularly helpful Moodlers
Hi Yong,

Which error did you receive after upgrading? I had to run a special mysql_upgrade tool after the upgrade. After that upgrade MariaDB ran without problems.