Mysql service not starting in windows 7




















Active 8 years, 11 months ago. Viewed 3k times. I tried starting mysqld manually and it says InnoDB: Error: log file. Akhil Achuthan Akhil Achuthan 2 2 silver badges 16 16 bronze badges.

Add a comment. Active Oldest Votes. Sign up or log in Sign up using Google. Sign up using Facebook. Sign up using Email and Password. Post as a guest Name. Email Required, but never shown. The Overflow Blog. Podcast Making Agile work for data science. To check the effect of specifying path options, invoke mysqld with those options followed by the --verbose and --help options.

You can specify other options such as --datadir as well, but --verbose and --help must be the last options. Once you determine the path settings you want, start the server without --verbose and --help. If mysqld is currently running, you can find out what path settings it is using by executing this command:. Make sure that the server can access the data directory. The ownership and permissions of the data directory and its contents must allow the server to read and modify them.

If you get Errcode 13 which means Permission denied when starting mysqld , this means that the privileges of the data directory or its contents do not permit server access. In this case, you change the permissions for the involved files and directories so that the server has the right to use them. You can also start the server as root , but this raises security issues and should be avoided.

Change location to the data directory and check the ownership of the data directory and its contents to make sure the server has access. If the data directory or its files or subdirectories are not owned by the login account that you use for running the server, change their ownership to that account. If the account is named mysql , use these commands:. Even with correct ownership, MySQL might fail to start up if there is other security software running on your system that manages application access to various parts of the file system.

In this case, reconfigure that software to enable mysqld to access the directories it uses during normal operation. Verify that the network interfaces the server wants to use are available. Use ps to determine whether you have another mysqld server running. If so, shut down the server before starting mysqld again. If another server is running, and you really want to run multiple servers, you can find information about how to do so in Section 5.

The default MySQL port number is Then press Enter a couple of times. Track down what program this is and disable it, or tell mysqld to listen to a different port with the --port option.

Another reason the port might be inaccessible is that you have a firewall running that blocks connections to it. You can also specify a --local-service option following the service name. This causes the server to run using the LocalService Windows account that has limited system privileges. If both --defaults-file and --local-service are given following the service name, they can be in any order. For a MySQL server that is installed as a Windows service, the following rules determine the service name and option files that the server uses:.

If the service-installation command specifies no service name or the default service name MySQL following the --install option, the server uses the service name of MySQL and reads options from the [mysqld] group in the standard option files. If the service-installation command specifies a service name other than MySQL following the --install option, the server uses that service name. It reads options from the [mysqld] group and the group that has the same name as the service in the standard option files.

This enables you to use the [mysqld] group for options that should be used by all MySQL services, and an option group with the service name for use by the server installed with that service name. If the service-installation command specifies a --defaults-file option after the service name, the server reads options the same way as described in the previous item, except that it reads options only from the named file and ignores the standard option files.

Here, the default service name MySQL is given after the --install option. If no --defaults-file option had been given, this command would have the effect of causing the server to read the [mysqld] group from the standard option files.

However, because the --defaults-file option is present, the server reads options from the [mysqld] option group, and only from the named file. On Windows, if the server is started with the --defaults-file and --install options, --install must be first.

Otherwise, mysqld. However, if there are any changes to that default setup for example, changes to the user who runs the service or to the mentioned user variables, or the --tmpdir option has been used to put the temporary directory somewhere else , the MySQL service might fail to run because write access to the temporary directory has not been granted to the proper user.

After a MySQL server instance has been installed as a service, Windows starts the service automatically whenever Windows starts. SC and NET commands are not case-sensitive. When run as a service, mysqld has no access to a console window, so no messages can be seen there. If mysqld does not start, check the error log to see whether the server wrote any messages there to indicate the cause of the problem.

It is the file with a suffix of. When a MySQL server has been installed as a service, and the service is running, Windows stops the service automatically when Windows shuts down. You also have the choice of installing the server as a manual service if you do not wish for the service to be started automatically during the boot process.

To do this, use the --install-manual option rather than the --install option:. Alternatively, use the mysqld --remove option to remove the service.



0コメント

  • 1000 / 1000