Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

The processing of starting error report in MySQL Database

2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)06/01 Report--

mysql Starting MySQL in Linux

The server quit without updating PID file. Here's how to solve it.

I found a bunch of methods from the Internet as follows:

1. The requested URL/data/rekfan.pid was not found on this server.

Solution:

Give permission to execute "chown -R mysql:mysql /var/data"

"chmod -R 755 /usr/local/mysql/data" and restart mysqld!

2. There may already be a mysql process in the process

Solution:

Use the command "ps -ef| grep mysqld"See if there is a mysqld process

If there is a kill using "kill -9 process number" then restart mysqld!

3. Probably the second time mysql is installed on the machine, there is residual data affecting the service startup

Solution:

Go to mysql data directory/data to see if mysql-bin.index exists

Remove it quickly, it is the culprit. I am using the third method to solve!

4.mysql uses the/etc/my.cnf configuration file when no configuration file is specified at startup

Please open this file to see if there is a specified data directory (datadir) under the [mysqld] section

Solution: Please set this line under [mysqld]: datadir = /usr/local/mysql/data

5.Skip-federated field problem

Solution: Check if there are any uncommented skip-federated fields in/etc/my.cnf file, and comment them out immediately if there are any.

6. Error log directory does not exist

Workaround: Use the "chown" "chmod" command to give mysql owner and permissions

7.Selinux caused trouble, if it is centos system, selinux will be turned on by default

Solution:

Close it, open/etc/selinux/config, change SELINUX=enforcing to SELINUX=disabled and save to exit and restart the machine

The requested URL/usr/local/mysql/data was not found on this server.

Problem solving should be permission problem, localhost.localdomain.pid file cannot be generated

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report