You are on page 1of 1

from terminal:

==============
sudo systemctl stop mysqld
sudo systemctl set-environment MYSQLD_OPTS="--skip-grant-tables"
sudo systemctl start mysqld
mysql -u root

from mysql prompt:


================
update mysql.user set plugin='mysql_native_password';
UPDATE mysql.user SET authentication_string = PASSWORD('welcome1') WHERE User =
'root';
FLUSH PRIVILEGES;
quit

from terminal:
==============
sudo systemctl stop mysqld
sudo systemctl unset-environment MYSQLD_OPTS
sudo systemctl start mysqld
mysql -u root -p

You might also like