MySQL on lion

CentOs中iptables配置允许mysql远程访问  

Iptables Allow MYSQL server incoming request on port 3306

CentOS 配置mysql允许远程登录 
mysql远程登录解决方法 

为根用户添加远程登录:

GRANT ALL PRIVILEGES ON *.* TO 'root'@'10.211.xx.8' IDENTIFIED BY 'youpassword' WITH GRANT OPTION;
FLUSH PRIVILEGES;

 添加新用户:

insert into mysql.user(Host,User,Password) values("localhost","youname",password("youpassword)"));
flush privileges;

create database accountdb;
grant all privileges on accountdb.* to 'youname'@'%' identified by 'youpassword)' with grant option;
flush privileges;
show grants for 'youname'@'%';

 查看用户:

select Host,User,Password from mysql.user;

 

 

 

 

 

 

posted @ 2013-03-01 10:54  chenjunbiao  阅读(214)  评论(0编辑  收藏  举报