contos系统mysql安装

  • 下载rpm安装文件
wget http://repo.mysql.com/mysql-community-release-el7-5.noarch.rpm
  • 安装rpm文件
rpm -ivh mysql-community-release-el7-5.noarch.rpm
  • 安装mysql-server
sudo yum install mysql-server
  • 启动mysql服务
service mysqld restart
  • 登录root账号
mysql -u root 
  • 切换到mysql数据库
use mysql;
  • 更新密码
update user set password=password('new password') where user='root';
  • 刷新生效
flush privileges;

猜你喜欢

转载自www.cnblogs.com/lynn16/p/10637992.html
今日推荐