Ripristinare la password dell’utente root di mysql

Accedere come root

# /etc/init.d/mysqld stop

Lanciare il server in modalità safe:

# mysqld_safe –skip-grant-tables &

# mysql -u root mysql

# UPDATE user SET password=PASSWORD(“passworddacambiare”) WHERE user=”root”;

# FLUSH PRIVILEGES;

# exit

# pkill mysql_safe

# /etc/init.d/mysqld start