I have installed MariaDB on Ubuntu LTS 16.04. Then I have run
/usr/bin/mysql_secure_installation
and set a root password. Accessing the DB via mysql -u root -p
works fine. But checking the status with service mysql status
opens a log file with this warning:
[Warning] 'user' entry 'root@localhost' has both a password and an authentication plugin specified. The password will be ignored.
The questions are:
- Is this a worry or completely normal?
- If this is a worry, how can I fix it?
It is normal, if by saying "accessing the DB via
mysql -u root -p
works fine" you mean that you are running it while being a system root (or undersudo
). You should not be able to do it as an ordinary user.Packages generated by Ubuntu by default have unix_socket authentication for the local root. To check, run
You should see
unix_socket
in theplugin
column forroot@localhost
.If you want to use the password authentication instead, run