search cancel

Mysql problem upgrading to 21.2.6/ 21.2.8 access denied for 'root'@'localhost'


Article ID: 238705


Updated On:


CA Spectrum


Upgrading from 21.2.4 to 21.2.6/21.2.8 the upgrade may fail with the following error:


The cause of failure could be a dis-alignment between the mysql root's password stored in myclient and the mysql root's password stored in mysql db.

This situation may occur if in 21.2.4 you tried to change the mysql root's password as documented at 


but you did not complete the change of it updating it also in mysql.



Release : 21.2.4,21.2.6,21.2.8

Component :


Before running the upgrade, if you have tried to change the mysql root's password, you can check if there is a dis-alignment as follow:

1) check the mysql root's password in Spectrum myclient  in the /my_print_defaults output
cd $SPECROOT/mysql/bin
export MYSQL_TEST_LOGIN_FILE=$SPECROOT/mysql/data/mylogin.cnf
./my_print_defaults -s --defaults-file=$SPECROOT/mysql/my-spectrum.cnf myclient
2) verify if you are able to manually login to mysql with the password returned by the ./my_print_defaults command
./mysql --defaults-file=$SPECROOT/mysql/my-spectrum.cnf -uroot -p<password>

 If you are able to login you can proceed with the upgrade otherwise you have to complete the change the mysql root's password (if it was interrupted) or change it back to the default value.