[ OK ]
Starting mysqld: [ OK ]
4、为MariaDB设置密码
# /usr/bin/mysqladmin -u root password 'adminadmin'
登陆MariaDB
MySQL [(none)]> use mysql;
MySQL [mysql]> update user set host='%' where user='root' and host='127.0.0.1';
MySQL [mysql]> grant all privileges on *.* to 'root'@'%' identified by 'adminadmin' with grant option;
MySQL [mysql]> flush privileges;
5、让防火墙通过3306端口
# vi /etc/sysconfig/iptables
添加如下内容:
-A INPUT -m state --state NEW -m tcp -p tcp --dport 3306 -j ACCEPT
保存并退出编辑
重启防火墙服务
# service iptables restart
远程连接检查,一切OK!
在 CentOS/RHEL/Scientific Linux 6 下安装 LAMP (Apache with MariaDB and PHP)
Ubuntu 上如何将 MySQL 5.5 数据库迁移到 MariaDB 10