真实的国产乱ⅩXXX66竹夫人,五月香六月婷婷激情综合,亚洲日本VA一区二区三区,亚洲精品一区二区三区麻豆

成都創(chuàng)新互聯(lián)網(wǎng)站制作重慶分公司

MySQL啟動失敗-創(chuàng)新互聯(lián)

一、錯誤日志:
[mysql@host-172-24-115-217 ~]$ service mysql restart
Shutting down MySQL.. SUCCESS!
Starting MySQL..180426 13:36:03 mysqld_safe Logging to '/usr/local/mysql/data/alert.log'.
180426 13:36:03 mysqld_safe Starting mysqld daemon with databases from /usr/local/mysql/data
.................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................. ERROR!
二、分析日志:
(1)查看日志
usr/local/mysql/data/alert.log
發(fā)現(xiàn):Version: '5.5.59-MariaDB'  socket: '/usr/local/mysql/data/mysql.sock'  port: 3306  MariaDB Server
表示mysqld 啟動完畢。
(2)查看進程
[mysql@host-172-24-115-217 fd]$ ps -ef | grep mysqld
mysql    20633     1  0 13:36 pts/5    00:00:00 /bin/sh /usr/local/mysql/bin/mysqld_safe --datadir=/usr/local/mysql/data --pid-file=/usr/local/mysql/data/mysqlProcess.pid
mysql    21736 20633  0 13:36 pts/5    00:00:02 /usr/local/mysql/bin/mysqld --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data --plugin-dir=/usr/local/mysql/lib/plugin --log-error=/usr/local/mysql/data/alert.log --pid-file=/usr/local/mysql/data/mysqlProcess.pid --socket=/usr/local/mysql/data/mysql.sock --port=3306
mysql    22436  7333  0 13:40 pts/3    00:00:00 grep mysqld
分析:
從日志和進程信息可以看出此mysqld服務正常。那為什么出現(xiàn)啟動失敗的現(xiàn)象。
三、挖掘原因
既然mysqld服務進程正常,那從其它機器是否可以登錄。經(jīng)過測試
[mysql@host-172-24-115-218 ~]$ mysql -h272.24.115.217 -uroot -pmysql
Welcome to the MariaDB monitor.  Commands end with ; or \g.
Your MariaDB connection id is 1
Server version: 5.5.59-MariaDB MariaDB Server
Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
MariaDB [(none)]>
經(jīng)過驗證,可以登錄。
四:結論
從此可以推斷
mysql服務器的client配置錯誤,導致mysql進程讀取配置導致異常
檢查/etc/my.cnf 發(fā)現(xiàn)如下:
[client]
#socket = /usr/local/mysql/data/mysql.sock
default-character-set = gbk
port = 3306
缺少紅色部分,注釋后,再次重啟一切正常。
希望改進:
希望mysql的啟動過程相關的shell腳本也能添加相應的日志,協(xié)助分析問題。
That is all.
Good Luck!

網(wǎng)站題目:MySQL啟動失敗-創(chuàng)新互聯(lián)
文章鏈接:http://weahome.cn/article/gcgds.html

其他資訊

在線咨詢

微信咨詢

電話咨詢

028-86922220(工作日)

18980820575(7×24)

提交需求

返回頂部