Remote connection to mysql: [1130, mysql: 1130]
The following error is returned when you remotely connect to mysql:
1130 -host 'localhost' is not allowed to connect to this mysql server
Solution
Log on to mysql with the root account locally, modify the user table of the mysql database and change the host field to %. The command is as follows:
mysql -uroot –p123mysql>use mysql;mysql>update user set host = '%' where user = 'root';
OK!
Mysql remote connection error 1130
What is the IP address of a linux server?
Then ping the IP address on the sub-command line of your machine to see if the IP address can be connected.
If the connection fails, it is estimated that it is not in a LAN.
If you can connect, it's not a network problem. It may be firewall restrictions or something else.
You need to find the problem and add it.
Supplement ----------------------
What tools do you use for remote connection? I use Ttermpro.
When sqlyog is used to remotely connect to MYSQL in LINUX, the following error occurs: 1130
The remote connection user cannot be granted permissions. As a result, the mysql database can be operated. After logging on to mysql on the local machine, change the "host" item in the "user" table in the "mysql" database, and rename it '%' from "localhost '..
Mysql-u root-p
Mysql> use mysql;
Mysql> select 'host' from user where user = 'root ';
Mysql> update user set host = '%' where user = 'root ';
Mysql> flush privileges;
Mysql> select 'host' from user where user = 'root ';
The first sentence is to authorize the User root to log on.
Second sentence: Select mysql database
Third sentence: view the host value of the user table in the mysql database (the host/IP name that can be accessed through connection)
Fourth sentence: Modify the host value (add host/IP address with the wildcard % content), of course, you can also directly add IP addresses
Fifth sentence: refresh the MySQL system permission table
The sixth statement is modified when you re-view the user table ..
Restart the mysql service.