In the first one it is looking for a DB in /var/lib/mysql
(the default) and in the second, it is looking in /data/mysql
, where you have moved to.
As we all know, mysqld_safe and mysqld are very different
mysqld : The database server instance daemon
mysqld_safe : Control program that examines and sets the environment for mysqld to execute. The mysqld executable is actually launched in a loop. When mysqld terminates, the mysqld_safe program will examine the return results and decide whether
- mysqld terminated normally (intentional shutdown), leaves mysqld_safe
- mysqld terminated abnormally (crash or kill -9 of mysqld)
- Loop back, mysqld fails on retry, leaves mysqld_safe
- Loop back, mysqld starts up, stays in the mysqld_safe loop
Why is it important to have mysqld and mysqld_safe using the same MySQL version?
Let me illustrate it this way: Percona Server sometimes has additional features in mysqld_safe for manipulating the OS. For example, I have seen numactl --interleave=all
in a Percona Server mysqld_safe. If that line was not there, the mysqld for Percona Server may run into issues with memory and swapping.
The same scenario could possibly be the case for Oracle's (ugh, still hate saying that) mysqld and mysqld_safe. There could be improvements from one major release to another that would be removed if the mysqld_safe was older.
Rather than exploring the possibilities of using a old mysqld_safe and a new mysqld (or vica versa), please make your life simple and reinstall MySQL 5.5.30 from scratch.
Before doing so, please run
updatedb
locate mysqld_safe
in Linux and see if there are two lingering. If there are, get the paths straightened out. Otherwise, you may have to reinstall MySQL 5.5.30.
Best Answer
The .ini needs to contain the plugin followed by the components.
The document Authentication Plugin - Unix Socket hints that the component name is
unix_socket
.So the correct contents of the file should be:
echo -e 'auth_socket\nunix_socket' >> /usr/lib/mariadb/plugin/unix_socket.ini
As a workaround use
plugin-load=auth_socket
in /etc/my.cnf.d/mariadb-server.cnf seems also sufficient.