ThinkChat2.0新版上线,更智能更精彩,支持会话、画图、阅读、搜索等,送10W Token,即刻开启你的AI之旅 广告
## mysql安装 ``` su wget http://dev.mysql.com/get/mysql-community-release-el7-5.noarch.rpm rpm -ivh mysql-community-release-el7-5.noarch.rpm yum install mysql-community-server service mysqld restart ``` ## 设置密码 ``` mysql -u root mysql> set password for 'root'@'localhost' =password('你的新密码'); --把在所有数据库的所有表的所有权限赋值给位于所有IP地址的root用户。 mysql> grant all privileges on *.* to root@'%'identified by '你的密码'; --新建用户 --mysql>create user 'username'@'%' identified by 'password'; ``` ## 测试 ``` mysql -u root -p mysql> show databases; ``` ## 最后,开放防火墙策略 ``` firewall-cmd --zone=public --add-port=3306/tcp --permanent ```