如果表/数据库损坏,是否可以手动删除它?如何清除ibdata双写缓冲区?
我刚刚恢复了我的服务器。但是mysql不会出现。错误消息建议设置innodb_force_recovery = 6。哪个允许启动mysql。所以我确定了缺陷表。但无论我尝试检查/修复/删除损坏的表/数据库,它总是以mysql停止并抛出错误:
ERROR 2013 (HY000): Lost connection to MySQL server during query
这是启动mysql的mysql错误日志:
140702 13:40:36 [Note] Plugin 'FEDERATED' is disabled.
140702 13:40:36 [Warning] option 'innodb-buffer-pool-size': signed value 2097152 adjusted to 5242880
140702 13:40:36 [Warning] option 'innodb-additional-mem-pool-size': signed value 512000 adjusted to 524288
140702 13:40:36 InnoDB: The InnoDB memory heap is disabled
140702 13:40:36 InnoDB: Mutexes and rw_locks use GCC atomic builtins
140702 13:40:36 InnoDB: Compressed tables use zlib 1.2.3.4
140702 13:40:36 InnoDB: Initializing buffer pool, size = 5.0M
140702 13:40:36 InnoDB: Completed initialization of buffer pool
140702 13:40:36 InnoDB: Log file ./ib_logfile0 did not exist: new to be created
InnoDB: Setting log file ./ib_logfile0 size to 5 MB
InnoDB: Database physically writes the file full: wait...
140702 13:40:37 InnoDB: Log file ./ib_logfile1 did not exist: new to be created
InnoDB: Setting log file ./ib_logfile1 size to 5 MB
InnoDB: Database physically writes the file full: wait...
140702 13:40:37 InnoDB: highest supported file format is Barracuda.
InnoDB: The log sequence number in ibdata files does not match
InnoDB: the log sequence number in the ib_logfiles!
140702 13:40:37 InnoDB: Database was not shut down normally!
InnoDB: Starting crash recovery.
InnoDB: Reading tablespace information from the .ibd files...
InnoDB: Restoring possible half-written data pages from the doublewrite
InnoDB: buffer...
InnoDB: Warning: database page corruption or a failed
InnoDB: file read of space 0 page 79918.
InnoDB: Trying to recover it from the doublewrite buffer.
InnoDB: Dump of the page:
140702 13:40:37 InnoDB: Page dump in ascii and hex (16384 bytes):
Hexdata
InnoDB: End of page dump
140702 13:40:37 InnoDB: Page checksum 3463763561, prior-to-4.0.14-form checksum 3074131693
InnoDB: stored checksum 2986557383, prior-to-4.0.14-form stored checksum 3074131693
InnoDB: Page lsn 3 3511673317, low 4 bytes of lsn at page end 3511673317
InnoDB: Page number (if stored to page already) 79918,
InnoDB: space id (if created with >= MySQL-4.1.1 and stored already) 0
InnoDB: Page may be an index page where index id is 5918
InnoDB: Dump of corresponding page in doublewrite buffer:
140702 13:40:37 InnoDB: Page dump in ascii and hex (16384 bytes):
Hexdata
...
InnoDB: End of page dump
140702 13:40:37 InnoDB: Page checksum 1693035738, prior-to-4.0.14-form checksum 533526999
InnoDB: stored checksum 1060638083, prior-to-4.0.14-form stored checksum 533526999
InnoDB: Page lsn 3 3511586897, low 4 bytes of lsn at page end 3511586897
InnoDB: Page number (if stored to page already) 79918,
InnoDB: space id (if created with >= MySQL-4.1.1 and stored already) 0
InnoDB: Page may be an index page where index id is 5918
InnoDB: Also the page in the doublewrite buffer is corrupt.
InnoDB: Cannot continue operation.
InnoDB: You can try to recover the database with the my.cnf
InnoDB: option:
InnoDB: innodb_force_recovery=6
140702 13:40:37 InnoDB: Assertion failure in thread 3064526592 in file trx0sys.c line 604
InnoDB: We intentionally generate a memory trap.
InnoDB: Submit a detailed bug report to http://bugs.mysql.com.
InnoDB: If you get repeated assertion failures or crashes, even
InnoDB: immediately after the mysqld startup, there may be
InnoDB: corruption in the InnoDB tablespace. Please refer to
InnoDB: http://dev.mysql.com/doc/refman/5.5/en/forcing-innodb-recovery.html
InnoDB: about forcing recovery.
11:40:37 UTC - mysqld got signal 6 ;
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=131072
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 = 346063 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 0x30000
/usr/sbin/mysqld(my_print_stacktrace+0x33)[0xb72a35c3]
/usr/sbin/mysqld(handle_fatal_signal+0x484)[0xb7150004]
[0xb6e0c500]
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.
有没有办法在mysql离线时删除数据库/表?
是否可以清除ibdata双写缓冲区,因为这是正常启动的博客mysql?