Forums

Rod_Bowden
Rod_Bowden
Offline
Resolved
0 votes
I am trying to do a backup. In my script I stop the service first. Then I am trying to do an mysqldump as per the below:

/usr/clearos/sandbox/usr/bin/mysqldump -u zarafa -p -v --single-transaction zarafa | gzip > /var/tmp/zarafadump.sql.gz
With this I get

Enter password: -- Connecting to localhost...
mysqldump: Got error: 1045: "Access denied for user 'zarafa'@'localhost' (using password: NO)" when trying to connect

If I do:
/usr/clearos/sandbox/usr/bin/mysqldump -uzarafa -pPassword -v --single-transaction zarafa | gzip > /var/tmp/zarafadump.sql.gz
mysqldump: Got error: 1045: "Access denied for user 'zarafa'@'localhost' (using password: YES)" when trying to connect

What am I doing wrong
Monday, June 22 2020, 09:39 AM
Share this post:
Responses (1)
  • Accepted Answer

    Monday, June 22 2020, 12:20 PM - #Permalink
    Resolved
    0 votes
    You are probably using the system-database (which is a sandboxed copy of mysql) and not mysql so you'll need to stop the system-database. Then, to access the sandboxed copy, you need to add "--port=3308" to your mysqldump command.
    The reply is currently minimized Show
Your Reply