Skip to main content

MySQL Service Status shows down while the service is running

Comments

6 comments

  • cPRex Jurassic Moderator
    Hey there! Is it possible that the MySQL server is so busy that the monitoring tools can't properly connect? You can see what MySQL is doing with the "mysqladmin proc status" command. If there are a very large number of queries per second or a large number of open tables, it's possible the monitoring tool is having issues detecting MySQL running properly.
    0
  • jndawson
    Hey there! Is it possible that the MySQL server is so busy that the monitoring tools can't properly connect? You can see what MySQL is doing with the "mysqladmin proc status" command. If there are a very large number of queries per second or a large number of open tables, it's possible the monitoring tool is having issues detecting MySQL running properly.

    The entire system sees very low activity: [ root@cp5 scripts># mysqladmin proc status +------+-------------+-----------+----+---------+------+--------------------------+------------------+----------+ | Id | User | Host | db | Command | Time | State | Info | Progress | +------+-------------+-----------+----+---------+------+--------------------------+------------------+----------+ | 2 | system user | | | Daemon | | InnoDB purge worker | | 0.000 | | 1 | system user | | | Daemon | | InnoDB purge coordinator | | 0.000 | | 3 | system user | | | Daemon | | InnoDB purge worker | | 0.000 | | 4 | system user | | | Daemon | | InnoDB purge worker | | 0.000 | | 5 | system user | | | Daemon | | InnoDB shutdown handler | | 0.000 | | 2170 | root | localhost | | Query | 0 | Init | show processlist | 0.000 | +------+-------------+-----------+----+---------+------+--------------------------+------------------+----------+ Uptime: 74494 Threads: 8 Questions: 10038 Slow queries: 0 Opens: 506 Flush tables: 1 Open tables: 499 Queries per second avg: 0.134
    0
  • cPRex Jurassic Moderator
    Thanks for that - is there anything in the MySQL error log that would provide more details?
    0
  • jndawson
    Thanks for that - is there anything in the MySQL error log that would provide more details?

    Does the mysql error log indicate when cpanel monitoring is screwed up? To clarify, mysql is running just fine. cpanel service status monitor indicates it's not running at all. We want to know why and fix it so the status monitor is no longer inaccurate.
    0
  • cPRex Jurassic Moderator
    Sure, it's possible there could be something in that log file that provides a clue. I'm a big fan of the phrase "never come up with reasons not to test something" and it wouldn't hurt to check the log just to see. You could also check the cPanel error log at /usr/local/cpanel/logs/error_log to see if anything shows up when the monitoring issue happens. If there's nothing in either of those locations, it would be best to create a ticket with our team so we can take a look at the server.
    0
  • jndawson
    Recap and update: Running MariaDB 10.3.35. Service Status suddenly started sending email notices every 5 minutes that MySQL/MariaDB was down, showing several mysql.tables corrupted due to Innodb errors. Restarting via whm didn't work according to displayed results. Restarting at cli didn't work according to displayed results. ps shows MySQL/MariaDB is actually running. Turned off service monitor. Checked the affected dB tables, which were mysql.tables, and discovered innodb errors. Ran repair on all tables - still corrupted. Checked whm > sql services > edit sql conf and discovered temp and max heap memory table sizes were 1/2 recommended amount. Fixed according to instructions on the page. Restarted MariaDB with no errors, restarted MariaDB service monitor. No more errors. Why it suddenly happened is unknown. Perhaps an upgrade changed things.
    0

Please sign in to leave a comment.