Ubuntu 安装 Mysql8 初始化 root 密码

安装

apt install mysql-server;

初始化

mysql_secure_installation

设置密码

set global validate_password_policy=LOW;
SET GLOBAL validate_password.length = 6;
ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY '123456';
posted @ 2024-09-25 10:49  vx_guanchaoguo0  阅读(33)  评论(0编辑  收藏  举报