首页 > 其他分享 >Tablespace 'innodb_system' Page [page id: space=0, page number=5] log sequence number 2243

Tablespace 'innodb_system' Page [page id: space=0, page number=5] log sequence number 2243

时间:2023-04-27 23:23:51浏览次数:35  
标签:log sequence number mysqld mysql InnoDB page

场景:

  这几天在外面实习,老师的项目数据库崩了让我看,连着两条看到十一二点,哎。

  主要场景是mysql突然崩溃,发现重启mysqld服务无效,重启系统无效。查看/var/log/mysql.log日志,看到以下内容:

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.
2023-04-26T02:58:51.457876Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.27) starting as process 2885
2023-04-26T02:58:51.489049Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
2023-04-26T02:58:53.107900Z 0 [ERROR] [MY-011971] [InnoDB] Tablespace 'innodb_undo_002' Page [page id: space=4294967278, page number=86] log sequence number 2243554633 is in the future! Current system log sequence number 2243439748.
2023-04-26T02:58:53.107987Z 0 [ERROR] [MY-011972] [InnoDB] Your database may be corrupt or you may have copied the InnoDB tablespace but not the InnoDB log files. Please refer to http://dev.mysql.com/doc/refman/8.0/en/forcing-innodb-recovery.html for information about forcing recovery.
2023-04-26T02:58:53.108163Z 0 [ERROR] [MY-011971] [InnoDB] Tablespace 'innodb_undo_002' Page [page id: space=4294967278, page number=198] log sequence number 2243516362 is in the future! Current system log sequence number 2243439748.
2023-04-26T02:58:53.108202Z 0 [ERROR] [MY-011972] [InnoDB] Your database may be corrupt or you may have copied the InnoDB tablespace but not the InnoDB log files. Please refer to http://dev.mysql.com/doc/refman/8.0/en/forcing-innodb-recovery.html for information about forcing recovery.
2023-04-26T02:58:53.108388Z 0 [ERROR] [MY-011971] [InnoDB] Tablespace 'innodb_undo_002' Page [page id: space=4294967278, page number=82] log sequence number 2243515454 is in the future! Current system log sequence number 2243439748.
2023-04-26T02:58:53.108420Z 0 [ERROR] [MY-011972] [InnoDB] Your database may be corrupt or you may have copied the InnoDB tablespace but not the InnoDB log files. Please refer to http://dev.mysql.com/doc/refman/8.0/en/forcing-innodb-recovery.html for information about forcing recovery.
2023-04-26T02:58:53.108474Z 0 [ERROR] [MY-011971] [InnoDB] Tablespace 'innodb_undo_002' Page [page id: space=4294967278, page number=195] log sequence number 2243515454 is in the future! Current system log sequence number 2243439748.
2023-04-26T02:58:53.108508Z 0 [ERROR] [MY-011972] [InnoDB] Your database may be corrupt or you may have copied the InnoDB tablespace but not the InnoDB log files. Please refer to http://dev.mysql.com/doc/refman/8.0/en/forcing-innodb-recovery.html for information about forcing recovery.
2023-04-26T02:58:53.108613Z 0 [ERROR] [MY-011971] [InnoDB] Tablespace 'innodb_undo_002' Page [page id: space=4294967278, page number=550] log sequence number 2243515454 is in the future! Current system log sequence number 2243439748.
2023-04-26T02:58:53.108650Z 0 [ERROR] [MY-011972] [InnoDB] Your database may be corrupt or you may have copied the InnoDB tablespace but not the InnoDB log files. Please refer to http://dev.mysql.com/doc/refman/8.0/en/forcing-innodb-recovery.html for information about forcing recovery.
2023-04-26T02:58:53.241299Z 0 [ERROR] [MY-011971] [InnoDB] Tablespace 'innodb_undo_001' Page [page id: space=4294967279, page number=200] log sequence number 2243554270 is in the future! Current system log sequence number 2243439748.
2023-04-26T02:58:53.241416Z 0 [ERROR] [MY-011972] [InnoDB] Your database may be corrupt or you may have copied the InnoDB tablespace but not the InnoDB log files. Please refer to http://dev.mysql.com/doc/refman/8.0/en/forcing-innodb-recovery.html for information about forcing recovery.
2023-04-26T02:58:53.241552Z 0 [ERROR] [MY-011971] [InnoDB] Tablespace 'innodb_undo_001' Page [page id: space=4294967279, page number=199] log sequence number 2243515924 is in the future! Current system log sequence number 2243439748.
2023-04-26T02:58:53.241599Z 0 [ERROR] [MY-011972] [InnoDB] Your database may be corrupt or you may have copied the InnoDB tablespace but not the InnoDB log files. Please refer to http://dev.mysql.com/doc/refman/8.0/en/forcing-innodb-recovery.html for information about forcing recovery.
2023-04-26T02:58:53.357605Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.
2023-04-26T02:58:54.736987Z 0 [ERROR] [MY-013183] [InnoDB] Assertion failure: fut0lst.ic:85:addr.page == FIL_NULL || addr.boffset >= FIL_PAGE_DATA thread 139700975163136
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/8.0/en/forcing-innodb-recovery.html
InnoDB: about forcing recovery.
02:58:54 UTC - mysqld got signal 6 ;
Most likely, you have hit a bug, but this error can also be caused by malfunctioning hardware.
Thread pointer: 0x7f0e980008c0
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 = 7f0eaaffcb30 thread_stack 0x100000
/usr/sbin/mysqld(my_print_stacktrace(unsigned char const*, unsigned long)+0x3d) [0x1fc33ad]
/usr/sbin/mysqld(handle_fatal_signal+0x30b) [0xee902b]
/lib64/libpthread.so.0(+0xf630) [0x7f0eef24e630]
/lib64/libc.so.6(gsignal+0x37) [0x7f0eed798387]
/lib64/libc.so.6(abort+0x148) [0x7f0eed799a78]
/usr/sbin/mysqld() [0xc3378c]
/usr/sbin/mysqld() [0x2225bfa]
/usr/sbin/mysqld() [0x222699c]
/usr/sbin/mysqld(trx_purge(unsigned long, unsigned long, bool)+0xf9) [0x2226fd9]
/usr/sbin/mysqld(srv_purge_coordinator_thread()+0x542) [0x21ffe52]
/usr/sbin/mysqld(std::thread::_State_impl<std::thread::_Invoker<std::tuple<Detached_thread, void (*)()> > >::_M_run()+0xc0) [0x2144d30]
/usr/sbin/mysqld() [0x2768100]
/lib64/libpthread.so.0(+0x7ea5) [0x7f0eef246ea5]
/lib64/libc.so.6(clone+0x6d) [0x7f0eed860b0d]


......

Trying to get some variables.
Some pointers may be invalid and cause the dump to abort.
Query (0): Connection ID (thread ID): 0
Status: NOT_KILLED

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.
2023-04-26T14:01:04.902755Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.27) starting as process 25053
2023-04-26T14:01:04.915843Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
2023-04-26T14:01:05.880916Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.
2023-04-26T14:01:06.272806Z 0 [ERROR] [MY-013183] [InnoDB] Assertion failure: fut0lst.ic:85:addr.page == FIL_NULL || addr.boffset >= FIL_PAGE_DATA thread 139919917815552
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/8.0/en/forcing-innodb-recovery.html
InnoDB: about forcing recovery.
14:01:06 UTC - mysqld got signal 6 ;
Most likely, you have hit a bug, but this error can also be caused by malfunctioning hardware.
Thread pointer: 0x7f41840008c0
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 = 7f41a4ff8b30 thread_stack 0x100000
/usr/sbin/mysqld(my_print_stacktrace(unsigned char const*, unsigned long)+0x3d) [0x1fc33ad]
/usr/sbin/mysqld(handle_fatal_signal+0x30b) [0xee902b]
/lib64/libpthread.so.0(+0xf630) [0x7f41ec6b1630]
/lib64/libc.so.6(gsignal+0x37) [0x7f41eabfb387]
/lib64/libc.so.6(abort+0x148) [0x7f41eabfca78]
/usr/sbin/mysqld() [0xc3378c]
/usr/sbin/mysqld() [0x2225bfa]
/usr/sbin/mysqld() [0x222699c]
/usr/sbin/mysqld(trx_purge(unsigned long, unsigned long, bool)+0xf9) [0x2226fd9]
/usr/sbin/mysqld(srv_purge_coordinator_thread()+0x542) [0x21ffe52]
/usr/sbin/mysqld(std::thread::_State_impl<std::thread::_Invoker<std::tuple<Detached_thread, void (*)()> > >::_M_run()+0xc0) [0x2144d30]
/usr/sbin/mysqld() [0x2768100]
/lib64/libpthread.so.0(+0x7ea5) [0x7f41ec6a9ea5]
/lib64/libc.so.6(clone+0x6d) [0x7f41eacc3b0d]

  其中最早的报错是:

Tablespace 'innodb_undo_002' Page [page id: space=4294967278, page number=86] log sequence number 2243554633 is in the future! Current system log sequence number 2243439748.

  由于系统是装在公司Windows的虚拟机上的(这个也离谱),猜测可能是硬件异常断电导致的,但实际没有得到验证。

解决:

  打算先备份数据库,然后重新安装mysql。

  因为之前从没备份过,所以赶紧设置InnoDB的备份参数。编辑/etc/my.cnf,添加以下代码:

innodb_force_recovery = 3

  这个参数的值为0-6,默认为0。从1开始一个个试过去,看能不能启动。一般在3的时候就可以启动mysql了,此时不能进行插入、删除、修改等操作,赶紧备份数据库。

  重装数据库。

  顺便在重装的时候遇到一个问题:reading initial communication packet

  是本地可以连接mysql,但是用navicat远程连接不上。可以试试以下操作:

  1. 在/etc/my.cnf文件中添加:

bind-address=0.0.0.0

  2.开放mysql远程连接,注意这个修改密码不同版本语句不一样

mysql -u root -p;
use mysql;
update user set Host='%' where User='root'; 
ALTER USER 'root'@'%' IDENTIFIED WITH mysql_native_password BY 'root';
flush privileges;

  3.我一开始用navicat是用ssh连接,发现怎么都登不上去,后来不用ssh就行。晕死

  其他:在重装之前也看了蛮多帖子的,都试了一下发现还是不行,最后还是重装。有没有办法不重装mysql就能恢复呢?希望能交流一下。

参考:

https://blog.csdn.net/oThrowsException/article/details/120290545

https://blog.csdn.net/qq_40907977/article/details/114842270

https://www.it1352.com/2131538.html

https://www.cnblogs.com/besehen/p/16056006.html

标签:log,sequence,number,mysqld,mysql,InnoDB,page
From: https://www.cnblogs.com/chenzibai/p/17360512.html

相关文章

  • 4~6Blog
    upbbbgk   1.前言:4~6次pta题目集难度上升,代码量增加,考察了对类的设计以及如何实现类间关系等。难度较大。涉及到了去重排序循环遍历等。还有API接口,JAVA自带的实现类,包装类,成员方法等,涉及的知识面更广更难。 2.设计分析: 7-1菜单计价程序-3:设计点菜计价程序,根据......
  • CF1814E Chain Chips & CF750E New Year and Old Subsequence - 动态 dp -
    一句话概括动态dp:用来解决带修改/多次区间询问的dp问题。将转移写成矩阵的形式,然后利用线段树求解区间问题/单点修改1814E注意一条边要么选2要么选0次,而且第一条边一定是选了2次。如果有一条边没选,那么这条边两侧的边一定都选了。设\(f_i\)代表考虑到第\(i\)条边,......
  • 题目集4~6的总结性Blog
    目录 1.前言2.设计与分析3.踩坑心得4.改进建议5.总结 1.前言题目集4: (训练自我学习能力,例如treeset与hashset用法,了解一些类中的方法) 菜单计价程序-3有重复的数据有重复的数据 单词统计与排序 面向对象编程(封装性) GPS测绘中度分秒转换 判断两个日期......
  • cnblogs 简洁模式 All In One
    cnblogs简洁模式AllInOnecnblogs简洁模式,显示文章阅读量总量和博客排名操作步骤打开一个非自己的账号的cnblogs博客首页⚠️注意博客皮肤一定要选择一个与自己的博客皮肤一致的才可以例如:CodingLifehttps://i.cnblogs.com/settingshttps://www.cnblogs.com/ano......
  • Logback日志输出配置和使用-要点攻略
    Logback是由log4j创始人设计的另一个开源日志组件,比log4j功能更强大,效率更高。官方网站:http://logback.qos.ch/documentation.html。本文较为详细地讲述logback的日志输出使用原理、如何配置,并结合具体的代码,给出程序调用的方法。为了讲清原理,本文从log4j的日志级别开讲,然后讲述......
  • 窗口函数DENSE_RANK()/DENSE_RANK()/ROW_NUMBER() 区别
    SQL语句之DENSE_RANK函数:DENSE_RANK()是一个窗口函数,它为分区或结果集中的每一行分配排名,而排名值没有间隙。DENSE_RANK()。如果使用DENSE_RANK()进行排名会得到:1,1,2,3,4。RANK()。如果使用RANK()进行排名会得到:1,1,3,4,5。ROW_NUMBER()。如果使用ROW_NUMBER()进行排名会得到:1,2......
  • Oracle WebLogic多个组件漏洞风险提示
    漏洞概述近日,WebRAY安全服务产品线监测到Oracle官方发布了安全更新,本次共发布了包含WebLogic在内的433个产品的安全补丁程序,其中CVE-2023-21912、CVE-2023-21996、CVE-2023-21964、CVE-2023-21931、CVE-2023-21979等较为严重。WebLogic是美国Oracle公司出品的一个applicationserve......
  • Kivy中的Logger组件用于记录应用程序的日志信息
    name:可选参数,指定Logger组件的名称。默认为root。level:可选参数,指定Logger组件的记录级别。默认为debug。propagate:可选参数,指定是否向父Logger组件传递记录消息。默认为True。handlers:可选参数,指定Logger组件的处理程序。默认为None。disabled:可......
  • APEX中:Dialog的做法(1):利用分支branch跳转 但是需要有提交
    ​APEX中:Dialog的做法(1):利用分支branch跳转但是需要有提交的动作 本文由OracleApex中文社区纯手工打造,希望初学朋友也能一看就明白!!原文以及本篇涉及第二部分Dialog的做法(2)请到:https://www.sqlu.cn/85.html查阅1:先做好一个Dialog类型的页面Page46;创建页面=>空白......
  • vant中van-dialog组件点击确认按钮禁止弹窗自动关闭
    1.在van-dialog组件中添加before-close属性,2.定义该方法newGroupBefColse(action,done){if(action=='confirm'&&!this.newFenzuName.trim()){done(false)}else{done(true)}......