mysql安装(yum源)

①、安装客户端
yum install mysql.x86_64 -y
②、安装服务器
yum install mysql-server.x86_64 -y
③、设置mysql开机启动
chkconfig mysqld on
④、启动mysql
/etc/init.d/mysqld start
⑤、设置mysql密码
mysql -u root
select user,host,password from mysql.user;
use mysql;
UPDATE user SET password=PASSWORD(“123456”) WHERE user=’root’;
flush privileges;
exit

你可能感兴趣的:(mysql)