I have installed Debian 9 only last week and installed the MySQL that comes with the distro:
# mysql
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MariaDB connection id is 16
Server version: 10.1.26-MariaDB-0+deb9u1 Debian 9.1
Copyright (c) 2000, 2017, Oracle, MariaDB Corporation Ab and others.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
So - I can connect without problems like that. However, I can't connect over TCP at all (don't worry about the password, it is only a demo one):
# mysql -h127.0.0.1 -uroot -pAtauseq01
ERROR 1698 (28000): Access denied for user 'root'@'localhost'
The same happens if I create a new user:
# mysql
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MariaDB connection id is 14
Server version: 10.1.26-MariaDB-0+deb9u1 Debian 9.1
Copyright (c) 2000, 2017, Oracle, MariaDB Corporation Ab and others.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
MariaDB [(none)]> create user 'jan'@'localhost' identified by 'Atauseq01';
Query OK, 0 rows affected (0.00 sec)
MariaDB [(none)]> grant usage on *.* to 'jan'@'localhost';
Query OK, 0 rows affected (0.00 sec)
MariaDB [(none)]> grant all on *.* to 'jan'@'localhost' with grant option;
Query OK, 0 rows affected (0.00 sec)
MariaDB [(none)]> Bye
# mysql -h127.0.0.1 -ujan@localhost -pAtauseq01
ERROR 1045 (28000): Access denied for user 'jan@localhost'@'localhost' (using password: YES)
I have changed the bind address:
bind-address = 0.0.0.0
And netstat -nap
shows MySQL listening on 0.0.0.0:3306
. Unfortunately the logs show no detail; mysqld's error log shows nothing at all, and various client tell me no more than 'access denied'. Also, telnet localhost 3306
actually gets a connection, so I know I get that far, at least.
Is there any way to get the MySQL log to show more detail?