Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

Changed MySQL root pw, Service Status: down (but it isn't)

Discussion in 'Database Discussion' started by APatchworkBoy, Oct 25, 2018.

  1. APatchworkBoy

    APatchworkBoy Active Member

    Joined:
    Feb 26, 2018
    Messages:
    25
    Likes Received:
    7
    Trophy Points:
    3
    Location:
    West Yorkshire, UK
    cPanel Access Level:
    Root Administrator
    Morning all - running v74.0.9, I've just reset the MySQL root password via WHM interface.

    Service Status now shows mysql is down - it isn't. It's up and running fine.

    Code:
    Service Name:    mysql
    Service Status:    failed ⛔
    Notification:    The service “mysql” appears to be down.
    Service Check Method:    The system’s command to check or to restart this service failed.
    Number of Restart Attempts:    2
    Service Check Raw Output:    (XID hxvggd) The service “mysql” failed to start with the message: Access denied for user 'root'@'localhost' (using password: YES)
    
    The subprocess “/usr/local/cpanel/scripts/restartsrv_mysql” reported error number 255 when it ended.
    
    Startup Log:    Starting MySQL. SUCCESS!
    
    Log Messages:    2018-10-25 13:25:46 32183 [Note] /usr/sbin/mysqld: ready for connections.
    2018-10-25 13:25:45 31784 [Note] /usr/sbin/mysqld: Shutdown complete
    2018-10-25 13:25:44 31784 [Note] /usr/sbin/mysqld: Normal shutdown
    2018-10-25 13:25:32 31784 [Note] /usr/sbin/mysqld: ready for connections.
    2018-10-25 13:24:02 31131 [Note] /usr/sbin/mysqld: Shutdown complete


    'sudo /scripts/restartsrv_mysql' appears to function perfectly when run by hand. No errors reported.

    Code:
    # sudo /usr/local/cpanel/scripts/restartsrv_mysql
    
    Waiting for “mysql” to restart ……waiting for “mysql” to initialize ………finished.
    
    
    Service Status
    
        mysql (/usr/sbin/mysqld --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib64/mysql/plugin --user=mysql --log-error=fqdn.err --open-files-limit=10000 --pid-file=/var/lib/mysql/fqdn.pid) is running as mysql with PID 812 (pidfile+/proc check method).
    
    
    Startup Log
    
        Starting MySQL. SUCCESS! 
    
    
    Log Messages
    
        2018-10-25 13:35:09 812 [Note] /usr/sbin/mysqld: ready for connections.
    
        2018-10-25 13:35:08 32728 [Note] /usr/sbin/mysqld: Shutdown complete
    
        2018-10-25 13:35:07 32728 [Note] /usr/sbin/mysqld: Normal shutdown
    
        2018-10-25 13:30:36 32728 [Note] /usr/sbin/mysqld: ready for connections.
    
        2018-10-25 13:30:35 32183 [Note] /usr/sbin/mysqld: Shutdown complete
    
    
    mysql restarted successfully.
    

    I spotted:
    Problem after mysql root password change

    And have followed the advice for resetting root password via CLI using mysql-init txt file to see if that resolves... it doesn't.

    Any suggestions to get Service Manager / Status to report correctly?
     
    #1 APatchworkBoy, Oct 25, 2018
    Last edited: Oct 25, 2018
  2. APatchworkBoy

    APatchworkBoy Active Member

    Joined:
    Feb 26, 2018
    Messages:
    25
    Likes Received:
    7
    Trophy Points:
    3
    Location:
    West Yorkshire, UK
    cPanel Access Level:
    Root Administrator
  3. GOT

    GOT Get Proactive! PartnerNOC

    Joined:
    Apr 8, 2003
    Messages:
    1,372
    Likes Received:
    154
    Trophy Points:
    193
    Location:
    Chesapeake, VA
    cPanel Access Level:
    DataCenter Provider
    You should go back and change it again via whm because it updates more than just the actual password.

    The service manager can lag by as much as 20 minutes. If it's still down after that as indicated (though not actually down) then we can look at other possibilities.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  4. APatchworkBoy

    APatchworkBoy Active Member

    Joined:
    Feb 26, 2018
    Messages:
    25
    Likes Received:
    7
    Trophy Points:
    3
    Location:
    West Yorkshire, UK
    cPanel Access Level:
    Root Administrator
    Well, had to go work from home cos #reasons... and returned to an email from the server stating:

    And indeed it had, so, I then changed the password in /root/.my.cnf to the one I wanted to set at the beginning of this post, THEN returned to WHM and changed the MySQL Root Password there to the same as the one I’d just specified in /root/.my.cnf - this time it’s worked.

    When I set it manually via CLI, I specified the same password as the one I’d just set via WHM, so technically all processes should have been followed internally...

    Theory: Appears the problem looks simply to have been that when I changed it via WHM the first time round, it didn’t update the passwords in /root/.my.cnf automatically, and that was causing Service Status to fail when checking, as the only difference this time around is that I’ve changed it by hand there first.
     
  5. GOT

    GOT Get Proactive! PartnerNOC

    Joined:
    Apr 8, 2003
    Messages:
    1,372
    Likes Received:
    154
    Trophy Points:
    193
    Location:
    Chesapeake, VA
    cPanel Access Level:
    DataCenter Provider
    So, this is resolved then?
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  6. APatchworkBoy

    APatchworkBoy Active Member

    Joined:
    Feb 26, 2018
    Messages:
    25
    Likes Received:
    7
    Trophy Points:
    3
    Location:
    West Yorkshire, UK
    cPanel Access Level:
    Root Administrator
    Appears to be, yes.
     
  7. cPanelLauren

    cPanelLauren Forums Analyst II Staff Member

    Joined:
    Nov 14, 2017
    Messages:
    5,815
    Likes Received:
    443
    Trophy Points:
    233
    Location:
    Houston
    cPanel Access Level:
    DataCenter Provider
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice