zoukankan      html  css  js  c++  java
  • mysql删除数据库文件ibdata1后引发的故障

    进行性能测试是发现大量报错:

    Duplicate entry主键重复


    可以看到mysql数据库中已经没有innodb引擎启动信息了

    之前发现ibdata1占用了大量硬盘,为了省出空间删除了数据库ibdata1文件
    此时,删除ibdata1和ib_logfile0,ib_logfile1...再次重启即可恢复正常
    需要注意的是,其中innodb引擎的表被破坏掉了,需要重新导入


    mysql> show engines;
    
    
    +--------------------+---------+----------------------------------------------------------------+--------------+------+------------+
    | Engine             | Support | Comment                                                        | Transactions | XA   | Savepoints |
    +--------------------+---------+----------------------------------------------------------------+--------------+------+------------+
    | MEMORY             | YES     | Hash based, stored in memory, useful for temporary tables      | NO           | NO   | NO         |
    | PERFORMANCE_SCHEMA | YES     | Performance Schema                                             | NO           | NO   | NO         |
    | MyISAM             | DEFAULT | MyISAM storage engine                                          | NO           | NO   | NO         |
    | BLACKHOLE          | YES     | /dev/null storage engine (anything you write to it disappears) | NO           | NO   | NO         |
    | MRG_MYISAM         | YES     | Collection of identical MyISAM tables                          | NO           | NO   | NO         |
    | CSV                | YES     | CSV storage engine                                             | NO           | NO   | NO         |
    | ARCHIVE            | YES     | Archive storage engine                                         | NO           | NO   | NO         |
    +--------------------+---------+----------------------------------------------------------------+--------------+------+------------+


    数据库日志报错部分:


  • 相关阅读:
    如何在IIS7/7.5上配置IISADMPWD
    运用DebugDiag诊断ASP.Net异常
    vuecli3修改项目启动端口
    彻底删除vscode及安装的插件和个人配置信息
    angular中的 input select 值绑定无效,以及多出一个空白选项问题
    简述MVC模式
    vuecli3 运行报错
    前端开发规范
    nodejs 下载最新版本
    小程序 自定义弹窗出现后存在滚动穿透问题
  • 原文地址:https://www.cnblogs.com/reblue520/p/6239828.html
Copyright © 2011-2022 走看看