远程访问mysql(转)
GRANT ALL PRIVILEGES ON *.* TO '<username>'@'<remote addr or %(for all ip addr)>'IDENTIFIED BY '<password>' WITH GRANT OPTION;
修改mysql的配置文件
在linux下,mysql的配置文件是/etc/mysql/my.cnf
修改bind-address为0.0.0.0或者mysql所在机器的IP
重启mysql
在远端访问mysql mysql -h <ip addr> -u <username> -p <password>
http://blog.csdn.net/ldar2011/article/details/42921381