Home >Database >Mysql Tutorial >远程连接mysql_MySQL

远程连接mysql_MySQL

WBOY
WBOYOriginal
2016-06-01 13:45:01877browse

bitsCN.com

以root权限进入mysql,执行
Sql代码 
GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY 'carmot' WITH GRANT OPTION; 
    FLUSH PRIVILEGES;
 
别的机器就可以连接了
 
Sql代码 
mysql -uroot -pcarmot -P3306 -h10.4.251.154 

作者“yufeng0471”
 

bitsCN.com
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn