When i am running mysqldump with user(lets say test) i am getting error message:
mysqldump: Got error: 1045: Access denied for user 'test'@'localhost' (using password: YES) when trying to connect
Although the database and user details are correct as i am able to login. Also when i use mysqldump without passing -p then it works fine and ask for user password.
mysqldump -u test -p dbtest > dbtest.sql
Enter password:
I tried to pass --port, -h 127.0.0.1 as mentioned in other threads but nothing works.