Skip to content
English
  • There are no suggestions because the search field is empty.

How to Reset MySQL Password Where Database is Running on Linux

This article will show you how to reset MySQL password

Stop CruzOC services:
    sudo service oware stop
    sudo service synergy stop
    sudo service owaredb stop

Create restore password file:
    echo "ALTER USER 'root'@'localhost' IDENTIFIED BY 'dorado';" > /home/synergy/restore_root_password.sql

Start mysql with restore password file:
    mysqld --secure_file_priv=/home/synergy --init-file=/home/synergy/restore_root_password.sql &

Wait until mysql starts

Bounce VM

Confirm mysql password has been updated
    mysql -u root -pdorado