Access Denied for User 'root'@'localhost' (using password: YES) mariadb on linux from windows HY000

Опубликовано: 07 Май 2023
на канале: linux-syr
1,081
10

can't connect to mysql mariadb server on linux from windows.error 2003 (hy000) can't connect to mysql server on 'localhost' (10061).
The "Access Denied for User 'root'@'localhost' (using password: YES)" error message indicates that the user is used to connect to the MySQL server from localhost and a password is required to complete authentication. However, the password provided is incorrect or the root user does not have the required permissions to access the database.
To resolve this issue try the following Steps:

make sure you have entered the correct username and password to connect to the database.

Reset the password: If you are sure that the password is incorrect, reset the root user's password using the MySQL command line tool.

Check remote user permissions
CREATE USER 'user'@'%' IDENTIFIED BY 'password';
GRANT ALL PRIVILEGES ON dbname.* TO 'user'@'%';
FLUSH PRIVILEGES;

Set port and bind address: /etc/mysql/mariadb.conf.d/50-server.cnf or in /etc/my.cnf or /etc/mysql/my.cnf