Configure a remote connection to mysql
MySQL>GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY 'yourpassword' WITH GRANT OPTION;
MySQL>FLUSH PRIVILEGES;
When you connect to mysql remotely
mysql -h127.0.0.1 -u root -p
Error:
ERROR 2003 (HY000): Can’t connect to MySQL Server on ‘127.0.0.1’ (111)
Solutions:
sudo vi /etc/mysql/my.cnf
Delete the following line.
#bind-address = 127.0.0.1
sudo /etc/init.d/mysql restart
Read More:
- How to Fix MySQL ERROR 1130 (HY000): Host ‘XXXX’ is not allowed to connect to this MySQL server
- [Solved] ERROR 2002 (HY000): Can’t connect to local MySQL server through socket’/var/lib/mysql/mysql.sock’ (2)
- ERROR 2002 (HY000): Can’t connect to local MySQL server through socket ‘/tmp/mysql.sock’
- MYSQL Enter password:ERROR 2003 (HY000): Can‘t connect to MySQL server on ‘localhost:3306‘
- Remote connection to MySQL database error: is not allowed to connect to this MYSQL server solution
- ERROR 2002 (HY000): Can’t connect to local MySQL server through socket ‘/var/run/mysqld/mysqld.sock’
- Mysql8.02/ubuntu 20 ERROR 1449 (HY000) [How to Solve]
- host ‘‘ is not allowed to connect to this mysql server Connect MYSQL Error
- MySql Install Error: Can‘t connect to local MySQL server through socket ‘/tmp/mysql.sock‘
- [Solved] MYSQL Command Execute Error: Can ‘t connect to local MySQL server through socket ‘/tmp/mysql.sock ‘(2) “
- How to Solve can‘t connect to local mysql server through socket ‘/var/lib/mysql/mysql.sock‘
- MySQL Error: errorCode 1130, state HY000 [How to Solve]
- [Solved] Error: ER_HOST_NOT_PRIVILEGED: Host ‘x.x.x.x‘ is not allowed to connect to this MySQL server
- [Solved] CentOS installs MySQL and starts MySQL with error 2002 (HY000)
- Idea connect mysql error Server returns invalid timezone. Go to’Advanced’ tab and set’serverTimezone’ property
- Mysql Flashback Warning: C:\Program Files\MySQL\MySQL Server 8.0\bin\mysql.exe
- MySQL Install Error: MySQL error 1042: Unable to connect to any of the specified MySQL hosts
- [Solved] mysqldump Command Error: Got error: 2002: “Can‘t connect to server on ‘127.0.0.1‘ (36)“ when trying to connect
- Navicat connected to Mysql error: Client does not support authentication protocol requested by server;
- How to Solve MYSQL Error: Failed to start MySQL 8.0 database server