deepin-linux_15.11安装Mysql

  • 安装

    sudo apt-get install -y mysql-server mysql-client
    
  • 设置密码

    sudo mysql -uroot -p ( 执行该条命令后直接回车进入 )
    
    update mysql.user set plugin="mysql_native_password" where user="root";
    
    grant all on *.* to root@"localhost";
    
    update mysql.user set authentication_string=password('这里填写新密码') where user='root'and Host = 'localhost';
    
    flush privileges;
    
  • 重开终端测试登录

    mysql -uroot -p
    
  • 输入密码回车即登陆成功~

发布了49 篇原创文章 · 获赞 29 · 访问量 1877

猜你喜欢

转载自blog.csdn.net/Brannua/article/details/105014296