Failed! Error: SET PASSWORD has no significance for user \’root\’@\’localhost\’ as the authentication method used doesn\’t store authentication data in the MySQL server. Please consider using ALTER USER instead if you want to change authentication parameters.
sudo mysql
ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password by 'my-secret-password';
上面的my-secret-password换成你的新密码,好像必须有大写小写数字和符号,好要大于8位
再执行
exit;
sudo mysql_secure_installation