产品服务AMH 免费服务器主机面板SSL证书 免费SSL证书申请 担保单 免费安全、零费率交易平台编程助手免费智能写代码、翻译AMYSQL 免费MySQL管理工具

AMH 社区首页

 AMH社区 - 开放自由有价值的社区

[综合话题] 求助!Mysql无法启动.前辈们进来看看.

Junway
铁牌会员
31.00 价值分

Junway 发表于 2014-06-12 15:24:56
本帖最后由 Junway 于 2014-6-12 16:46 编辑

现在自己解决了..是因为使用wwwroot\domian\tmp下面产生了94G的临时文件.. 导致磁盘100%. 删掉tmp就好了.
另外请问管理员
wwwroot\domian\tmp是什么?为什么会产生如此大的临时文件
狠狠的扇了自己几个耳光.. 就因为这个问题. 纠结了整整一天. 全部注意力全几种到了mysql..到头来和MYSQL无关.. 以后排错得全方位排查了.


以下问题已解决
=============================================================


今天网站502 bad gateway. 简要检查下无果.遂直接重启服务器.结果mysql无法启用.百度谷歌几个小时无果.特向各位前辈请教.
现在唯一的奢求是能备份出数据库.. 重装mysql也无妨.

# mysql restart 错误如下
=============================================================
ERROR! MySQL server PID file could not be found!
Starting MySQL.. ERROR! The server quit without updating PID file (/usr/local/mysql/data/AY1405191822541604eaZ.pid).

#mysql -u root -p 错误如下:
=============================================================
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)

# mysqld_safe &
错误如下
=============================================================
[1] 10781
140612 15:00:42 mysqld_safe Logging to '/usr/local/mysql/data/AY1405191822541604eaZ.err'.
140612 15:00:42 mysqld_safe Starting mysqld daemon with databases from /usr/local/mysql/data
140612 15:00:43 mysqld_safe mysqld from pid file /usr/local/mysql/data/AY1405191822541604eaZ.pid ended

/tmp/mysql.sock 不存在此文件..
>ln -s /var/lib/mysql/mysql.sock /tmp/mysql.sock 无效
后发现mysql也不存在mysql.sock..
于是#find -name mysql.sock 发现mysql.sock丢失

于是放弃 想用mysqldump 导出数据后重装
# mysqldump -u root -p dbname> dbname.sql
mysqldump: Got error: 2002: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) when trying to connect

/etc/my.cnf 配置如下:
=============================================================
[client]
port = 3306
socket = /tmp/mysql.sock

[mysqld]
default-storage-engine = MyISAM
port = 3306
socket = /tmp/mysql.sock
skip-external-locking
key_buffer_size = 16M
max_allowed_packet = 1M
table_open_cache = 64
sort_buffer_size = 512K
net_buffer_length = 8K
read_buffer_size = 256K
read_rnd_buffer_size = 512K
myisam_sort_buffer_size = 8M
log-bin = mysql-bin
binlog_format = mixed
server-id = 1

[mysqldump]
quick

[mysql]
no-auto-rehash

[myisamchk]
key_buffer_size = 20M
sort_buffer_size = 20M
read_buffer = 2M
write_buffer = 2M

[mysqlhotcopy]
interactive-timeout


/usr/local/mysql/data/AY1405191822541604eaZ.err 错误日志如下:
=============================================================
140612 14:55:47 mysqld_safe Starting mysqld daemon with databases from /usr/local/mysql/data
140612 14:55:47 InnoDB: The InnoDB memory heap is disabled
140612 14:55:47 InnoDB: Mutexes and rw_locks use GCC atomic builtins
140612 14:55:47 InnoDB: Compressed tables use zlib 1.2.3
140612 14:55:47 InnoDB: Initializing buffer pool, size = 128.0M
140612 14:55:47 InnoDB: Completed initialization of buffer pool
140612 14:55:47 InnoDB: highest supported file format is Barracuda.
140612 14:55:47 InnoDB: Waiting for the background threads to start
140612 14:55:48 InnoDB: 5.5.34 started; log sequence number 1595685
06:55:48 UTC - mysqld got signal 11 ;
This could be because you hit a bug. It is also possible that this binary
or one of the libraries it was linked against is corrupt, improperly built,
or misconfigured. This error can also be caused by malfunctioning hardware.
We will try our best to scrape up some info that will hopefully help
diagnose the problem, but since we have already crashed,
something is definitely wrong and this may fail.

key_buffer_size=16777216
read_buffer_size=262144
max_used_connections=0
max_threads=151
thread_count=0
connection_count=0
It is possible that mysqld could use up to
key_buffer_size + (read_buffer_size + sort_buffer_size)*max_threads = 134092 K bytes of memory
Hope that's ok; if not, decrease some variables in the equation.

Thread pointer: 0x0
Attempting backtrace. You can use the following information to find out
where mysqld died. If you see no messages after this, something went
terribly wrong...
stack_bottom = 0 thread_stack 0x40000
/usr/local/mysql/bin/mysqld(my_print_stacktrace+0x2e)[0x75a0ce]
/usr/local/mysql/bin/mysqld(handle_fatal_signal+0x41a)[0x64f57a]
/lib64/libpthread.so.0(+0xf710)[0x7ff321f6a710]
The manual page at http://dev.mysql.com/doc/mysql/en/crashing.html contains
information that should help you find out what is causing the crash.
140612 14:55:48 mysqld_safe mysqld from pid file /usr/local/mysql/data/AY1405191822541604eaZ.pid ended

2014-06-12 15:24:56 1

Yusky
金牌会员
11307.70 价值分

你是不是开日志了?
  支持 (0分)  反对 (0分)
回复  2014-06-13 09:35:40 2

Junway
铁牌会员
31.00 价值分

引用:
Yusky 发表于 2014-6-13 09:35
你是不是开日志了?


没有. 日志都是关闭的.



  支持 (0分)  反对 (0分)
回复  2014-06-15 20:27:04 3

Yusky
金牌会员
11307.70 价值分

引用:
Junway 发表于 2014-6-15 20:27
没有. 日志都是关闭的.


要么就是被黑了。。。
  支持 (0分)  反对 (0分)
回复  2014-06-15 23:18:47 5

Junway
铁牌会员
31.00 价值分

引用:
Yusky 发表于 2014-6-15 23:18
要么就是被黑了。。。


今天又有80多G的日志啊.. 被黑不应该吧.
  支持 (0分)  反对 (0分)
回复  2014-06-16 12:17:59 6

894849635
金牌会员
15129.94 价值分

/home/wwwroot/domain/tmp/是Php程序调用期间产生的临时文件
如果不行的话直接删,新建文件,授权不可写不可读
  支持 (0分)  反对 (0分)
回复  2014-06-16 13:24:57 7

amysql
创始人
99530.81 价值分

amh不会有这么大的临时文件。
看下生成的都是些什么文件。
  支持 (0分)  反对 (0分)
回复  2014-06-17 11:40:23 8

AMH面板 - 好用高效低占用、安全可靠极稳定

zcom
银牌会员
1669.33 价值分

本帖最后由 zcom 于 2014-6-23 10:12 编辑

支持哈哈临时文件这事我还没遇到过,MYSQL的问题我遇到几次了,基本知道是怎么回事了,解决方法看我的帖子
  支持 (0分)  反对 (0分)
回复  2014-06-22 20:41:37 9
 1  (总1页)
AMH社区列表
用户服务中心