Rumah >pangkalan data >tutorial mysql >mysql 开启远程登录_MySQL
两步开启mysql远程连接
一,登录mysql
# mysql -uroot -p
二,配置远程连接
mysql > GRANT ALL PRIVILEGES ON *.* TO 'user1'@'%'IDENTIFIED BY 'mypassword';
或
mysql > GRANT ALLPRIVILEGES ON *.* TO 'root'@'%';
mysql > FLUSH PRIVILEGES;