1

My MySQL was not responsive and I tried restarting the MySql server. Now for more than 2 hrs, it's stuck at the "Server shutdown in progress" stage. I need to bring the service back as soon as production is down. Please suggest what can be done here.

Thanks in advance.

6
  • Check local server console, check for disk activity and wait until it's done. You could also tell us more about your SQL server.
    – paladin
    Commented Apr 8 at 11:20
  • Any specific command output is needed?
    – Enihr
    Commented Apr 8 at 11:29
  • Of course, anything that might be a hint why this server needs so long for shutting down.
    – paladin
    Commented Apr 8 at 11:35
  • Any specific command output is needed? The MySQL server is Ver 8.0.36-0ubuntu0.20.04.1 for Linux on x86_64 ((Ubuntu)). And the storage is an extended logical volume.
    – Enihr
    Commented Apr 8 at 11:36
  • Also 126G space is left on the device.
    – Enihr
    Commented Apr 8 at 11:51

1 Answer 1

0

Check mysqladmin processlist. It's possible some nasty query really is still running. Mysqld shouldn't start any new queries when it is reporting shutdown in progress.

If it really is idle, then try mysqladmin shutdown. This is probably the command used in your unit file but worth running again. Give it a few minutes. If still running, try killall -TERM mysqld - again wait a few minutes.

If the service is still running, then you'll need to crash mysqld to get it to stop: killall -KILL mysqld. Expect the startup to take longer with a chance of data corruption.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .