Maaz Zindani

Loading the index…

↑↓ move↵ openesc close4072 pages
Databases and Redis

MySQL is installed on Windows but there is no MySQL service

ErrorNET START MySQL fails because no service named MySQL exists

Short answer

A Windows MySQL service exists only after mysqld --install registers it. An install done by hand, without the configurator, can leave you with no service. Run the command from an administrator prompt with the full path, then start the service. If a service exists under another name, look for it in the Services utility and use that name.

  • Applies to MySQL 8.4 LTS, Windows 11
  • Updated
  • By Maaz Zindani, Senior Software Engineer

Fix it fast

  1. 1Find out which cause you have

    Open the Services utility and look for any MySQL entry, whatever it is called. Then check that the server program is on disk.

    dir "C:\Program Files\MySQL\MySQL Server 8.4\bin\mysqld.exe"
    NET START MySQL
  2. 2Match what you see, then jump to its fix

    1. 1Services has no MySQL entry, and mysqld.exe existsThe service was never installedFix
    2. 2Services shows a MySQL-related entry whose name is not MySQLThe service exists under a different nameFix
    3. 3Access is denied, or the install command printed an error and no service appearedThe install or start was done without administrator rightsFix

What does the error look like?

  • NET START MySQL fails because no service named MySQL exists
  • MySQL does not appear in the Services utility

Cause 1 of 3

The service was never installed

1Check

A service exists only after mysqld --install has registered it, and that command does not start the server.

"C:\Program Files\MySQL\MySQL Server 8.4\bin\mysqld" --version

2Fix

From a command prompt opened as administrator, install the service, then start it. Use --install-manual if Windows should not start it at boot.

"C:\Program Files\MySQL\MySQL Server 8.4\bin\mysqld" --install
NET START MySQL

3Verify

The start command reports success.

NET START MySQL

Confirmed by dev.mysql.com

Did this fix it?

Cause 2 of 3

The service exists under a different name

1Check

The default service name is MySQL, but a different name can be given right after --install. Read the name in the Services utility.

# Services utility: note the Service name of the MySQL entry

2Fix

Use the real name in the start command. When you install with your own name and options, put --install first, or mysqld.exe tries to start the server instead.

NET START MySQL84
"C:\Program Files\MySQL\MySQL Server 8.4\bin\mysqld" --install MySQL --defaults-file=C:\my-opts.cnf

3Verify

The command reports that the service started.

NET START MySQL84

Confirmed by dev.mysql.com

Did this fix it?

Cause 3 of 3

The install or start was done without administrator rights

1Check

Installing a service needs an account with administrator rights. Close the Services utility while installing or removing from the command line, to avoid conflicts.

# Title bar of the prompt should read Administrator

2Fix

Open the command prompt with Run as administrator, close Services, and repeat the install.

"C:\Program Files\MySQL\MySQL Server 8.4\bin\mysqld" --remove
"C:\Program Files\MySQL\MySQL Server 8.4\bin\mysqld" --install

3Verify

Start the service and read the status.

NET START MySQL

Confirmed by dev.mysql.com

Did this fix it?

How do I stop it coming back?

  • Write down the service name you chose, and use it in scripts.
  • Check the .err file in the data directory first when the service installs but will not start.
  • Update any script that holds the full path to mysqld.exe when you move to a new version.

Sources

How was this page made?

I drafted this page with AI assistance from the official documents listed under Sources. Every cause above names the document that confirms it. I have not reproduced this fix on a machine of my own yet, so read it as documented guidance, not a test report. Found a mistake? Tell me.

Which stack is behind this page?

Projects of mine built on the same technologies:

Related fixes

Next step

Want this handled for good?

I look after servers, apps and releases end to end. Tell me what keeps breaking.