当前位置:网站首页>MySQL database error The server quit without updating PID file (/var/lib/mysql/localhost.localdomain.pid)
MySQL database error The server quit without updating PID file (/var/lib/mysql/localhost.localdomain.pid)
2022-08-05 08:09:00 【nihui123】
Introduction
Because the server is powered off, the database cannot be connected. I found a lot of examples on the Internet. What permissions are not enough, and what needs to run the initialization script?They did not solve the problem in a timely and fast manner, but brought more problems.
As shown in the figure, this error is reported as soon as the database service is started.Checked for a long time

Solutionp>
Directly find the my.cnf file in the /etc directory and replace the following configuration into it.Then modify it according to your own directory configuration
[mysqld]bind-address=0.0.0.0port=3306user=mysql## This place is modified to the path of personal configurationbasedir=/usr/local/mysqldatadir=/data/mysqlsocket=/tmp/mysql.socklog-error=/data/mysql/mysql.errpid-file=/data/mysql/mysql.pid#character configcharacter_set_server=utf8mb4symbolic-links=0explicit_defaults_for_timestamp=trueOne thing to note here is that if the configuration is not appropriate, the following error will appear, but don't worry, there must be a pid file under the path you configured.So either specify the file directly or delete it. After the database service is started, it will be recreated.

Finally perfect launch

The method is real and effective, if it's not suitable, please @blogger in the comment area, the blogger must help solve it!
边栏推荐
- D2--FPGA SPI interface communication2022-08-03
- Data source object management Druid and c3p0
- Embedded Systems: Basic Timers
- 彩绘漂亮MM集
- uniapp时间组件封装年-月-日-时-分-秒
- 【深度学习实践(一)】安装TensorFlow
- openSource 知:社区贡献
- Support touch screen slider carousel plugin
- [Structural Internal Power Cultivation] The Mystery of Enumeration and Union (3)
- Random code generation
猜你喜欢

微信 小程序 之PC端 不支持 wx.previewMedia 方法 故用自定义轮播图进行 模拟照片视频的播放

学习笔记14--机器学习在局部路径规划中的应用

JVM运行流程,运行时数据区,类加载,垃圾回收,JMM解析

php fails to write data to mysql

餐饮大单品「真香」,却没有穿透周期的能力

Data source object management Druid and c3p0

php向mysql写入数据失败

uniapp时间组件封装年-月-日-时-分-秒

D2--FPGA SPI interface communication2022-08-03

VXE-Table融合多语言
随机推荐
行业应用软件项目经理三步曲
餐饮大单品「真香」,却没有穿透周期的能力
导出SQLServer数据到Excel中
Beautifully painted MM set
Qt writes custom controls: one of the text spotlight effects
唤醒手腕 - 微信小程序、QQ小程序、抖音小程序学习笔记(更新中)
作为一个男人必须明白的22个道理
JS实现从照片中裁切自已的肖像
Fiddler工具讲解
程序设计中的感悟
moment的使用
谷歌零碎笔记之MVCC(草稿)
SVG Star Wars Style Toggle Toggle Button
【每日一题】1403. 非递增顺序的最小子序列
剑指Offer面试题解总结1-10
pnpm 是凭什么对 npm 和 yarn 降维打击的
Version number naming convention
SVG星球大战样式Toggle切换开关按钮
C-Eighty seven(背包+bitset)
EA谈单机游戏:仍是产品组合中极其重要的部分