nanjingnan 发表于 2017-3-22 20:08:24

lnmp mysql 启动错误带错误日志 (以解决谢军哥)。急!!!

aStarting MySQL.. ERROR! The server quit without updating PID file (/usr/local/mysql/var/host-163-44-149-204.pid

[ 本帖最后由 nanjingnan 于 2017-3-25 12:25 编辑 ]

licess 发表于 2017-3-23 09:02:21

170322 19:05:50 Retry in 60 secs. Message reprinted in 600 secs
170322 19:06:06 Disk is full writing './mysql-bin.000050' (Errcode: 28). Waiting for someone to free space... (Expect up to 60 secs delay for server to continue after freeing disk space)
170322 19:06:06 Retry in 60 secs. Message reprinted in 600 secs
170322 19:06:50 Disk is full writing './dswnoswnzskd/pre_forum_post.TMD' (Errcode: 28). Waiting for someone to free space... (Expect up to 60 secs delay for server to continue after freeing disk space)
170322 19:06:50 Retry in 60 secs. Message reprinted in 600 secs
170322 19:07:06 Disk is full writing './mysql-bin.000050' (Errcode: 28). Waiting for someone to free space... (Expect up to 60 secs delay for server to continue after freeing disk space)
170322 19:07:06 Retry in 60 secs. Message reprinted in 600 secs
.............
170322 19:10:38 Error in Log_event::read_log_event(): 'read error', data_len: 76, event_type: 2
170322 19:10:38 Starting crash recovery...
170322 19:10:38 Crash recovery finished.
11:10:38 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=500
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 = 406149 Kbytes 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)
/usr/local/mysql/bin/mysqld(handle_fatal_signal+0x41a)
/lib64/libpthread.so.0(+0xf7e0)
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.

应该是当前分区或磁盘空间已满,可以df -h看一下占用情况

nanjingnan 发表于 2017-3-23 09:24:48

47G   15G   30G34% /
tmpfs               499M   0499M   0% /dev/shm
/dev/vda1             477M   63M389M14% /boot

删除了20多g日志后 还是不能启动。
目前的错误提示



[ 本帖最后由 nanjingnan 于 2017-3-23 10:07 编辑 ]

licess 发表于 2017-3-23 14:00:58

回复 3# 的帖子

1703239:33:15 InnoDB: 5.5.48 started; log sequence number 1595685
/usr/local/mysql/bin/mysqld: File './mysql-bin.000052' not found (Errcode: 13)
1703239:33:15 Failed to open log (file './mysql-bin.000052', errno 13)
1703239:33:15 Could not open log file
1703239:33:15 Can't init tc log
1703239:33:15 Aborting

1703239:33:15InnoDB: Starting shutdown...
清空mysql-bin.index 应该就可以了

nanjingnan 发表于 2017-3-23 17:08:28

数据库可以启动了。我的是discuz系统 目前出现错误。我直接把mysql-bin.index 删除了。删除后可以启动了。但是还是数据错误。是不是因为我没有正确的清楚清空mysql-bin.index,按照网上的方法不知道怎么清除。
(144) Table './数据库名/forum_post' is marked as crashed and last (automatic?) repair failedSELECT distinct authorid as uid,author as username FROM forum_post where invisible=0 and dateline>1487674919 order by dateline DESC
PHP Debug
No.FileLineCode1forum.php65runhooks()2source/function/function_core.php1120hookscript(%s, %s, %s, Array, %s, %s)3source/function/function_core.php1167plugin_nimba_nge_forum->index_top(Array)4source/plugin/nimba_nge/hook.class.php365plugin_nimba_nge->nge_userlist()5source/plugin/nimba_nge/hook.class.php325discuz_database::query(%s)6source/class/discuz/discuz_database.php136db_driver_mysql->query(%s, false, false)7source/class/db/db_driver_mysql.php153db_driver_mysql->halt(%s, %d, %s)8source/class/db/db_driver_mysql.php224break()
尝试了修复表。在phpmyamdin 但是没有作用。。求帮忙看看。
如果还是要修复表,麻烦军哥告诉我修复的方法(linux里),我用的网上的貌似不对。
路径方面我还特地按照lnmp的路径来的。




[ 本帖最后由 nanjingnan 于 2017-3-23 20:11 编辑 ]

licess 发表于 2017-3-24 09:47:51

回复 5# 的帖子

日志和之前的是一样的

/usr/local/mysql/bin/mysql -uroot -p
use 数据库名;
repair table 表名;
修复成功的话可以输入 exit; 退出

不行的话可以cd 到数据库目录后 尝试使用 /usr/local/mysql/bin/myisamchk -o -r 表名.MYI 运行前需要先停掉mysql

也可以尝试/usr/local/mysql/bin/mysqlcheck -r 数据库名 表名 -uroot -p 进行修复

nanjingnan 发表于 2017-3-24 13:34:41

真心感谢军哥 ,我自己尝试解决了。是修复表就好了。我是停止数据库 然后强制修复的。早上弄好了。太感谢了。
页: [1]
查看完整版本: lnmp mysql 启动错误带错误日志 (以解决谢军哥)。急!!!