Problem:
- There is no indication mysqld is actually reading the server manifest and/or the keyring component configuration file. Any help would be greatly appreciated.
System Info:
- Ubuntu 20.04
- MySQL 8.0.29
Details:
- All files are in the default locations where "sudo apt-get install mysql-server" puts them.
- mysql-server package came from Ubuntu repos.
What I've tried:
Per the MySQL docs, I created "a global manifest file named mysqld.my in the mysqld installation directory", and tried placing it in the following locations without success:
(NOTE: Owner:group:perms == root:mysql:640)- /usr ('basedir' location)
- /usr/sbin/ (mysqld binary location) [file is currently here]
- /var/lib/mysql ('datadir' location) [ASIDE: If I were using a global and a local manifest, the local manifest goes here according to the mysql docs.]
- /usr/lib/mysql/plugin/ ('plugin_dir' location)
Per the MySQL docs, I created "a global configuration file named component_keyring_file.cnf in the directory where the component_keyring_file library file is installed" in the following location:
(NOTE: Owner:group:perms == root:mysql:640)- /usr/lib/mysql/plugin/ ('plugin_dir' location. File 'component_keyring_file.so' does exist here.)
I used the following test with an initial condition that mysqld was not running:
- Place the global manifest in one of the folders listed.
- Start mysqld. ("sudo service mysql start")
- Verify mysqld started. ("sudo service mysql status")
- Check keyring component status: mysql -v -v -v -uREDACTED -pREDACTED -e "SELECT * FROM performance_schema.keyring_component_status;"
- Stop mysqld. ("sudo service mysql stop")
- Verify mysqld stopped. ("sudo service mysql status")
- Repeat at step #1 for next file location.
In all cases the SELECT query returned "Empty set".
Finally, I tried changing the permissions on the global manifest to 660 in the hope that I would see a warning in the MySQL error.log, but there is still nothing in the error.log that indicates the keyring component loaded before InnoDB is initialized. (Reason: The MySQL docs stated "server access to a manifest file should be read only. For example, a mysqld.my server manifest file may be owned by root and be read/write to root, but should be read only to the account used to run the MySQL server. If the manifest file is found during startup to be read/write to that account, the server writes a warning to the error log suggesting that the file be made read only.")
End Result: I'm running out of ideas, and I'm hoping one of you can point me in the right direction.
Other info:
- I'm aware there is plenty of info on how to configure the keyring plugin, but apparently the component is newer and offers more features/flexibility which is why I was attempting to use it.
- If it helps, here's where I started from on the MySQL docs: https://dev.mysql.com/doc/refman/8.0/en/innodb-data-encryption.html#innodb-data-encryption-about