Page MenuHomeDevCentral

Mount mysql-innodb-data and mysql-innodb-logs ZFS datasets outside /var/db/mysql
Closed, ResolvedPublic

Description

On db-B cluster, SHOW DATABASES; shows some specific ZFS dataset as subfolders (and so potential database):

#mysql50#mysql-innodb-data
#mysql50#mysql-innodb-logs
mysql-innodb-data
mysql-innodb-logs

When running that command the following errors are logged in /var/log/mysql/mysqld.err:

2024-10-26 23:35:19 574563 [ERROR] Invalid (old?) table or database name 'mysql-innodb-data'
2024-10-26 23:35:19 574563 [ERROR] Invalid (old?) table or database name 'mysql-innodb-logs'

This is because mounting points for ZFS datasets are in /var/db/mysql:
https://devcentral.nasqueron.org/source/operations/browse/main/roles/dbserver-mysql/mysql-server/zfs.sls

They contain the following data:

$ cd /var/db/mysql
$ ls mysql-innodb-data
ib_buffer_pool  ibdata1         ibtmp1
$ ls mysql-innodb-logs
ib_logfile0

Paths need also to be updated here: https://devcentral.nasqueron.org/source/operations/browse/main/roles/dbserver-mysql/mysql-server/zfs.sls

Event Timeline

dereckson triaged this task as High priority.Oct 26 2024, 21:58
dereckson created this task.
dereckson added a project: good-first-issue.
dereckson moved this task from Backlog to Ops on the good-first-issue board.
dereckson moved this task from Backlog to Working on on the Servers board.

Avancement sur T2074

Modifié le fichier roles/dbserver-mysql/mysql-server/zfs.sls : changement du point de montage de mysql-root de /var/db/mysql vers /var/db/mysql/data.
Cette première étape prépare la restructuration complète. Les systèmes de fichiers mysql-innodb-data et mysql-innodb-logs restent temporairement sous /var/db/mysql/.

Prochaine étape : Déployer sur WindRiver pour valider la modification.

Deployed on WindRiver.

Next: deploy on db-B-001

Mounting the ZFS datasets mysql-innodb-data and mysql-innodb-logs outside of /var/db/mysql, then deploying them to db-B-001: operation completed and functional.