I just installed MariaDB (mysqld) on a fresh Ubuntu downloaded yesterday. Then I ran the script
/usr/bin/mysql_secure_installation
and set new root password and disabled passwordless login. However this didn't work so I tried form the command line:
root@www:~# mysqladmin password whatever
root@www:~# mysql -uroot
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MariaDB connection id is 35
Server version: 10.0.24-MariaDB-7 Ubuntu 16.04
Copyright (c) 2000, 2016, Oracle, MariaDB Corporation Ab and others.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
MariaDB [(none)]> \q
Bye
root@www:~#
root@www:~# mysql -uroot -plkasjfdklajsfd
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MariaDB connection id is 38
Server version: 10.0.24-MariaDB-7 Ubuntu 16.04
Copyright (c) 2000, 2016, Oracle, MariaDB Corporation Ab and others.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
MariaDB [(none)]> use mysql
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Database changed
MariaDB [mysql]> select Host , User, Password from user;
+-----------+------+-------------------------------------------+
| Host | User | Password |
+-----------+------+-------------------------------------------+
| localhost | root | *90837F291B744BBE86DF95A37D2B2524185DBBF5 |
+-----------+------+-------------------------------------------+
1 row in set (0.00 sec)
Why does mysql ignores my password change instructions and worse , it allows passwordless login as root?