Sunday, 7 September 2014

Bitten by MySQL/MariaDB and lost+found

I should have remembered this, but MySQL or (MariaDB in my case) isn't entirely happy with running o its own partition under Linux, mostly as it tried to load the lost+found directory as a database.

For my OpenStack build, I need a database, and MariaDB with Galera clustering can provide an ha option for this - wr already have a pair of GPFS servers, so this seems a reasonable place to hold the relatively low load database to underpin it. More on that elsewhere though!

Anyway, Id like it to ideally run from a separate logical volume under Linux and whilst MariaSB will do this (with the odd whinge in a log file due to the lost+found), I found that xtrabackup (part of Percona for hot db backups) isn't so happy.

I was using this with the Galera clustering to do node synchronisation, but it kept failing with a permission denied error.

After a bit of digging around, I found it was caused by xtrabackup trying to sync the lost+found directory, it also appears that it doesn't like the ignore-db-dir config option.

So I've reverted to having /var/lib as a partition. Best compromise I can find really...!

One other quirk I found with xtrabackup, it needs the datadir defining and reads it from the MySQL config, only problem is on EL 6 etc, this is in an included file and xtrabackup appears not to traverse the included file so I've ended up defining it twice.

Anyway, a good half day wasted trying to get the sync working...! (yes I don't expect to have to reinstall any db nodes later, but Id like them to be able to DR using xcat.).

No comments:

Post a comment