xml

Well-Known Member
Jan 15, 2004
89
3
158
Hello

from user account shell and for years I been using this comandline
mysqldump --opt -Q –uusername –ppassword database_name > Backup.sql

lately that comandline isnt working any more and get this error message:
mysqldump: Got error: 1044: Access denied for user 'user'@'localhost' to database '–uusername' when selecting the database

But I found this comandline is working:
mysqldump --opt -Q database_name > Backup.sql

why the first comandline is not working any more? and why the second comandline is working without username and password, isnt it security risk?


CENTOS 6.6 x86_64 standard
WHM 11.44.1 (build 23)
 
Last edited:

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,910
2,212
363
Hello :)

You should already have authenticated into the account when you accessed SSH so you should be able to simply run:

Code:
mysqldump --opt -Q database_name > Backup.sql
Thank you.