CentOS 6.9安装MySQL 5.1.73(6)

[root@cdh1 linuxidc]# mysql
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection
id is 2
Server version:
5.1.73 Source distribution

Copyright (c)
2000, 2013, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and
/or its
affiliates. Other names may be trademarks of their respective
owners.

Type
'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql
> \q
Bye

9、设置mysql开机启动

[root@cdh1 linuxidc]# chkconfig mysqld on

10、开启3306端口,并保存

[root@cdh1 linuxidc]# /sbin/iptables -I INPUT -p tcp --dport 3306 -j ACCEPT [root@cdh1 linuxidc]# /etc/rc.d/init.d/iptables save

11、连接mysql设置密码

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:https://www.heiqu.com/8d0263968aa84a6681f2b791e6f09f28.html