Sometimes we want to connect mysql on our computer on other computers, what should we do at this time?
mysql>use mysql;
mysql>select host,user,password from user;
View to localhost root hgfhahgahghahhahgjhgh
Need to modify localhost to "%", use update sql statement
mysql>update user set host='%' where user='root';
mysql>select host,user,password from user;
View to % root hgfhahgahghahhahgjhgh
refresh operation
mysql>flush privileges;
At this point, you can connect to your database remotely