MySQL service won’t start, Error 5

MySQL

The MySQL56 service will not start giving me the error:

Windows could not start the MySQL56 service on Local Computer.

Error 5: Access is denied.

The last time I was able to get into MySQL was the 11th, but the next day the service would not start. I have full write permissions for the directory that it is installed in and it is not a mapped drive.

From the .err file, it looks like the last shutdown never completed. The last entry is:

2014-07-11 16:48:31 2864 [Note] InnoDB: Starting shutdown...

whereas other showdown events give the Shutdown complete log.

Any ideas about how to get it back up and running?

Windows 7 Home Premium,
MySQL 5.6

Best Answer

  1. Download Microsoft SysInternals' ProcessMonitor and run it as an administrator.
  2. Start the MySQL Service
  3. Once the error happens, stop ProcessMonitor from capturing more events (File Menu -> untick Capture Events)
  4. Search (Ctrl+F) for ACCESS DENIED - it shows up in the Result column

If you find any denied entries, the information will show you what process was running, and what file or registry key it was trying to access. That's the one you need to sort out.

Double click on a row to open the properties, look at the 'process' tab, that can show you which user account was being used by the process.

How you fix it depends on what's wrong - maybe it's a file in use that can't be opened, maybe it's file or registry permissions you can change, maybe something is running as the wrong account... but this should tell you some details you can work with. What's denied, and where.