ib iblogfile0 能删除吗怎么查看

mysql - InnoDB: Error: log file ./ib_logfile0 is of different size - Server Fault
to customize your list.
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.
Here's how it works:
Anybody can ask a question
Anybody can answer
The best answers are voted up and rise to the top
I just added the following lines in /etc/f after I converted one database to use InnoDB engine.
innodb_buffer_pool_size = 2560M
innodb_log_file_size
innodb_log_buffer_size
innodb_flush_log_at_trx_commit
innodb_thread_concurrency
innodb_flush_method = O_DIRECT
But it raise "ERROR 2013 (HY000) at line 2: Lost connection to MySQL server during query" error restarting mysqld. And mysql error log shows the following
InnoDB: Error: log file ./ib_logfile0 is of different size 0 5242880 bytes
InnoDB: than specified in the .cnf file 0
:52:52 [ERROR] Plugin 'InnoDB' init function returned error.
:52:52 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
:52:52 [ERROR] Unknown/unsupported table type: InnoDB
:52:52 [ERROR] Aborting
So I commented out this line
# innodb_log_file_size
And it restarted mysql successfully.
I wonder what's the "5242880 bytes of log file" showed in mysql error? It's the first database on InnoDB engine on this server so when and where is that log file created? In this case, how can I enable innodb_log_file_size directive f?
I tried to delete /var/lib/mysql/ib_logfile0 and restart mysqld but it still failed. It now shows the following in error log.
InnoDB: Log file ./ib_logfile0 did not exist: new to be created
InnoDB: Setting log file ./ib_logfile0 size to 256 MB
InnoDB: Database physically writes the file full: wait...
InnoDB: Progress in MB: 100 200
InnoDB: Error: log file ./ib_logfile1 is of different size 0 5242880 bytes
InnoDB: than specified in the .cnf file 0
Resolution
It works now after deleted both ib_logfile0 and ib_logfile1 in /var/lib/mysql
InnoDB is insanely picky about it' if something's not right, it'll just give up and go home.
To make a change to the log file size without data loss:
Revert any config changes you've made to the log file size and start MySQL again.
In your running MySQL: SET GLOBAL innodb_fast_shutdown=0;
Stop MySQL
Make the configuration change to the log file size.
Delete both log files.
Start MySQL.
It will complain about the lack of log files, but it'll create them and all will be well.
73.5k9110177
protected by ♦
Thank you for your interest in this question.
Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10
on this site.
Would you like to answer one of these
Not the answer you're looking for?
Browse other questions tagged
Server Fault works best with JavaScript enabledMySQL :: ibdata1 , ib_logfile0 and ib_logfile1ib logfile-中国学网
ib logfile
状态:1个回答日期:回答人:偷星1478问:请问,我没有启用二进制日志,如果误删可以通过ib_logfile文件恢复数据吗?答:不能,只有通过备份文件(MYSQLDUMP生成),用于存放InnoDB引擎的事务日志信息的 ib_logfiles的作用,主要是在系统崩溃重启时,作事务重做的。 查看原帖&& 采纳哦状态:1个回答日期:回答人:答:必须把以前的mysql的残留信息给删除干净,先把注册表中的有关mysql的注册表删除:ib_logfile0 ib_logfile1 ibdata1 重启服务,再次生成就OK了 这样,TaCrkR状态:1个回答日期:回答人:MBD_诠释梦想答:他是记录数据库事物的日志 直接打开就可以了状态:2个回答日期:回答人:8462gadl问:这二个文件很大,占用了空间,我每次备份都很费时间和容量,想知道删除...答:删了,你的数据就没了。不能删除状态:3个回答日期:回答人:Dear_An问:会有什么结果?答:不太清楚状态:1个回答日期:回答人:中国学网网友问:报错文件如下: :23:13 [Note] Plugin 'FEDERATED' is disable...答:InnoDB: Error: log file .\ib_logfile0 is of different size 0
bytesInnoDB: than specified in the .cnf file 0
bytes!:23:...状态:2个回答日期:回答人:todh问::45:35 [Note] Plugin 'FEDERATED' is disabled. :45...答:InnoDB: Error: log file .\ib_logfile0 is of different size 0
bytesInnoDB: than specified in the .cnf file 0
bytes!:45:...状态:1个回答日期:回答人:fallsoft问:这是err的内容 [Note] Plugin 'FEDERATED' is disabled. [Note] InnoDB:...答:[Note] InnoDB: Setting log file .\ib_logfile101 size to 10 MB [Note] InnoDB: Setting log file .\ib_logfile1 size to 10 MB[Note] InnoDB: Renamin...状态:1个回答日期:回答人:中国学网网友答:ibdata1 、ib_logfile0 、ib_logfile1 、.frm、.MYM、.MYI文件都有,不过因为数据表结构是MYISAM类型,估计&MYM文件的内容已经是更新后的了。...
与【ib logfile】相关信息:&&&&&&&&&&&&&&&&&&&&
用户还关注
大类导航: |Mysql启动中 InnoDB: Error: log file ./ib_logfile0 is of different size 0 5242880 bytes 的问题
字体:[ ] 类型:转载 时间:
对于使用了默认 my.cnf(一般教程都会教你使用support-files/f)的Mysql服务来说如果中间使用了innodb的话,innodb默认的log file大小是56M
如果你的配置文件使用了类似my-innodb-f作为配置文件的话。 Mysql可以正常启动,但innodb的表无法使用 在错误日志里你会看到如下输出: InnoDB: Error: log file ./ib_logfile0 is of different size 0 5242880 bytes 现在需要做的事情就是把原来的 innodb 的ib_logfile×备份到一个目录下,然后删除掉原来的文件,重启 mysql。 你会看到ib_logfile*大小变成了你配置文件中指定的大小。 my-innodb-f的话(log file 的大小是256M:innodb_log_file_size = 256M) 你会看到很多个大小的文件。
您可能感兴趣的文章:
大家感兴趣的内容
12345678910
最近更新的内容
常用在线小工具ib_logfile1-中国学网
ib_logfile1
状态:2个回答日期:回答人:8462gadl问:这二个文件很大,占用了空间,我每次备份都很费时间和容量,想知道删除...答:删了,你的数据就没了。不能删除状态:1个回答日期:回答人:sunpian2问:新建同样数据库后,把备份的文件覆盖上,mysql启动报错1067,log文件内...答:你这个备份是直接复制文件的吗?还是通过mysqldump命令备份来的?状态:2个回答日期:回答人:阳光上的桥答:这些文件是innodb的事务日志文件,没法直接阅读.状态:3个回答日期:回答人:Dear_An问:会有什么结果?答:不太清楚状态:1个回答日期:回答人:答:必须把以前的mysql的残留信息给删除干净,先把注册表中的有关mysql的注册表删除:ib_logfile0 ib_logfile1 ibdata1 重启服务,再次生成就OK了 这样,TaCrkR状态:1个回答日期:回答人:中国学网网友问::17:50 [Note] Plugin 'FEDERATED' is disabled. :17...答:InnoDB: Setting log file .\ib_logfile1 size to 10 MBInnoDB: Database physically writes the file full: wait...InnoDB: Doublewrite buffer not found: ...状态:2个回答日期:回答人:《赖》问:apmserv 5.2.6 MySQL5.1启动失败,请检查相关配置。进入服务手动启动APM...答:你看下任务管理器里面有没mysqld-nt.exe进程,有的话结束它再启动服务看下。 如果仍然启动不了,你就把mysql安装目录下的date目录下里的“ibdata1、ib_logfile1、ib_logfile0”这三个文件删了 再启动服务(备注:这三个文件时启动mysql时产生的文...状态:1个回答日期:回答人:问:windows7操作系统APMServ5.2.6里4.0版本启动正常 MYSQL5.1无法启动 请求...答:windows7操作系统APMServ5.2.6里4.0版本启动正常 MYSQL5.1无法启动 请求帮助附...InnoDB: Setting log file .\ib_logfile0 size to 5 MBInnoDB: Database ...状态:3个回答日期:回答人:奋斗收获在08问::55:48 InnoDB: Error: unable to c err...答:通过删除数据文件夹ib_logfile0 ib_logfile1 和ibdata1文件附创建mysql服务,cmdsc create service-name 运行mysqld -install安装mysql服务 运行mysqld -install安装...状态:1个回答日期: 这些文件是innodb的事务日志文件,没法直接阅读.状态:1个回答日期: 删了,你的数据就没了。不能删除状态:1个回答日期: 不太清楚状态:1个回答日期:所以,你想要起什么样的数据库名称就把文件夹起什么名字。
然后把.frm文件导进去。注意还要在data目录下加入ib_logfile0,ib_logfile1,ibdata1这几个文件。
要不然在mys...状态:1个回答日期: 一般是某个软件产生的日志文件,可以删除。状态:1个回答日期:.ibd文件:单表表空间文件,每个表使用一个表空间文件(file per table),存放用户数据库表数据和索引 日志文件: ib_logfile1、ib_logfile2 二、MySQL数据库存放位置: 1、MySQL如果...状态:1个回答日期:修改MySQL安装目录下的my.ini,在skip-innodb前增加#,重启MySQL,然后用show engines命令查看InnoDB的值是不是yes?3、停掉mysql服务,然后删除ib_logfile0和ib_logfile1文件...状态:1个回答日期:你看下任务管理器里面有没mysqld-nt.exe进程,有的话结束它再启动服务看下。
如果仍然启动不了,你就把mysql安装目录下的date目录下里的"ibdata1、ib_logfile1、ib_logfile0...状态:1个回答日期:data 文件下的MYSQL的文件夹出现了问题。
可能某些设置 文件在这里面。
用以前的data 文件夹,不包含2个文件(ib_logfile0 ib_logfile1,其实就是这两个文件损坏了。)。复制...状态:1个回答日期:找到default-storage-engine=InnoDB这一行,把它改成default-storage-engine=MyISAM。
2、删除在MySQL安装目录下的Data目录中的
ib_logfile0
ib_logfile1
3。找到在配置...
与【ib_logfile1】相关信息:&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
用户还关注
12345678910
大类导航: |

我要回帖

更多关于 ib logfile0 恢复数据 的文章

 

随机推荐