MySQL database with RPM package after installation, a series of problems, the following will start to answer
1. After the installation is complete, service MySQL start, normal start
Use MySQL or mysql-u root-p to enter directly, the following error is reported
ERROR 1045 (28000): Access denied for user ' root ' @ ' localhost ' (using Password:no)
The solution is as follows:
Service MySQL stop mysqld_safe--user=mysql--skip-grant-tables--skip-networking & mysql-u root-p Direct Carriage Enter EXECUTE statement use MySQL UPDATE user SET Password=password (' Your_newpassword ') where user= ' root '; Flush privileges; Quit service MySQL start mysql-u root-p Enter the password you just modified to enter
2. The above problem is solved, then the problem comes again, after landing to look at the database bar,
show databases;
Results:!!
ERROR 1820 (HY000): Must SET PASSWORD before executing this statement
The solution is as follows:
SET PASSWORD = PASSWORD (' Your_newpassword '); Get the return value to OK and try again, show databases; you'll find it normal.
MySQL cannot log on after installation is complete.