Error message:
mysqldump: Got error: 1045: Access denied for user ‘root’@’localhost’ (using pas
sword: YES) when trying to connect
Operating environment: CMD
You can log into mysql normally with root-@localhost, but mySQldump denied access, checked the root permission, found that there was no problem with the permission, and finally decided to create a new experiment account
mysqldump: Got error: 1045: Access denied for user ‘root’@’localhost’ (using pas
sword: YES) when trying to connect
Operating environment: CMD
You can log into mysql normally with root-@localhost, but mySQldump denied access, checked the root permission, found that there was no problem with the permission, and finally decided to create a new experiment account
CREATE USER dumper@'localhost' IDENTIFIED BY 'dumper';
GRANT select ON test.* TO dumper@localhost;
GRANT show view ON test.* TO dumper@localhost;
GRANT trigger ON test.* TO dumper@localhost;
GRANT lock tables ON test.* TO dumper@localhost;
Dumper is set to back up the Test library, can log in to the database normally, and still cannot access mySQldump
I began to add parameters to mySQldump gradually, and finally found that the access was successful after adding port -P3307
mysqldump -udumper -pdumper -hlocalhost -P3307 test>test.sql
According to the configuration file, the port of mysql has been modified to 3307, but mySQldump defaults to 3306. After that, the root account can also be normally backed up
Read More:
- An error occurred when MySQL backup with mysqldump instruction in MacOS system
- Error in exporting MySQL database from Linux mysqldump:got error :1045
- 【Exception】mysqldump: Error 2013: Lost connection to MySQL server during query when dumping table…
- mysqldump: Got error: 1016: Can’t open file: ‘./xxx.frm’ (errno: 24) when using LOCK TABLES
- Solution to the problem of Chinese garbled in gradle console in idea
- Solution to error: no devices found in ADB command
- Solution to the problem that listen TCP 0.0.0.0:3306: bind: address already in use port is occupied in Linux centos7
- Solution to communication link failure with error in idea startup project
- Solution to error 2002 (HY000) in MySQL login startup
- The solution to “polling news feeds” appeared in Eclipse in Java
- The use of Chinese characters in Qt and the solution to the “error C2001: newline in constant” problem
- Failed in Android compilation: solution to setup Jack server problem
- Solution to error 2002 (HY000) in MySQL
- Solution to MySQL Error 1130 problem
- Solution to unknown internal error in StarUML installation extension
- Solution of error converting data type varchar to datetime in SQL Server
- Solution to the exception of PEM file logging in EC2
- Solution to 1030 got error 28 from storage engine in MySQL
- Solution to the problem of unable to open glaux. H in vs2013
- Solution to the error code of 0x80040154 in COM / ole call