The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

mysqladmin: connect to server at 'localhost' failed

Discussion in 'Database Discussions' started by chips12, Nov 18, 2010.

  1. chips12

    chips12 Active Member

    Joined:
    Nov 6, 2010
    Messages:
    25
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    UK
    For the last couple of days I have been receiving an email whenever the optimisefs cron runs.

    saying:
    Code:
    /usr/bin/mysqladmin: connect to server at 'localhost' failed
    error: 'Access denied for user 'root'@'localhost' (using password: YES)'
    
    This is the cron that runs, a system process I think,

    Code:
    /usr/bin/test -x /usr/local/cpanel/bin/optimizefs && /usr/local/cpanel/bin/optimizefs
    I have tried resetting the sql root password, but when i start mysql then check
    mysqladmin proc

    I get the same error that the connection failed using the password.

    I am not sure what to do or why this has suddenly started happening.
     
  2. chips12

    chips12 Active Member

    Joined:
    Nov 6, 2010
    Messages:
    25
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    UK
    I thought I would post how I fixed this, just in case anyone googles the same error and finds the question...

    I had changed the mysql root password and being security conscious had used a mixture of alpha numeric AND special characters.

    It was the special characters in the password that were causing the problem. I changed the password to be just alpha numeric and root@localhost was able to connect to mysql once again.
     
Loading...

Share This Page