mysql无法启动 Could not open log file

由于服务器空间不够,mysql 无法启动 

Starting MySQL... ERROR! The server quit without updating PID file (/usr/local/mysql/var/xxx.pid).

 

就把mysql-bin.000070的文件删了,结果重启后出现错误

 

171203 14:26:11 [Note] /usr/local/mysql/bin/mysqld (mysqld 5.5.48-log) starting as process 3914 ...
171203 14:26:12 [Note] Plugin 'FEDERATED' is disabled.
171203 14:26:12 InnoDB: The InnoDB memory heap is disabled
171203 14:26:12 InnoDB: Mutexes and rw_locks use GCC atomic builtins
171203 14:26:12 InnoDB: Compressed tables use zlib 1.2.3
171203 14:26:12 InnoDB: Initializing buffer pool, size = 4.0G
171203 14:26:12 InnoDB: Completed initialization of buffer pool
171203 14:26:12 InnoDB: highest supported file format is Barracuda.
171203 14:26:12  InnoDB: Waiting for the background threads to start
171203 14:26:13 InnoDB: 5.5.48 started; log sequence number 191234988217
/usr/local/mysql/bin/mysqld: File './mysql-bin.000070' not found (Errcode: 2)
171203 14:26:13 [ERROR] Failed to open log (file './mysql-bin.000070', errno 2)
171203 14:26:13 [ERROR] Could not open log file
171203 14:26:13 [ERROR] Can't init tc log
171203 14:26:13 [ERROR] Aborting

171203 14:26:13  InnoDB: Starting shutdown...
171203 14:26:14  InnoDB: Shutdown completed; log sequence number 191234988217
171203 14:26:14 [Note] /usr/local/mysql/bin/mysqld: Shutdown complete

 

 

于是尝试先注释掉my.cnf   log-bin

log-bin=mysql-bin配置与主从配置有关,并且它记录了所有数据库的操作,用于灾难恢复,所以注释掉它也是有一定风险的,需要定时备份数据库!

posted @ 2017-12-03 14:44  私家菜地  阅读(5604)  评论(1编辑  收藏  举报