MariaDB报错Plugin 'InnoDB' init function returned error.解决方案

重新安装MariaDB后,服务一直启动不起来,查看日志有以下错误:

    InnoDB: No valid checkpoint found.
    InnoDB: If you are attempting downgrade from MySQL 5.7.9 or later,
    InnoDB: please refer to http://dev.mysql.com/doc/refman/5.6/en/upgrading-downgrading.html
    InnoDB: If this error appears when you are creating an InnoDB database,
    InnoDB: the problem may be that during an earlier attempt you managed
    InnoDB: to create the InnoDB data files, but log file creation failed.
    InnoDB: If that is the case, please refer to
    InnoDB: http://dev.mysql.com/doc/refman/5.6/en/error-creating-innodb.html
    170928 14:28:08 [ERROR] Plugin 'InnoDB' init function returned error.
    170928 14:28:08 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
    170928 14:28:08 [Note] Plugin 'FEEDBACK' is disabled.
    170928 14:28:08 [ERROR] Unknown/unsupported storage engine: InnoDB
    170928 14:28:08 [ERROR] Aborting

从网上找了大半天,都说把原来的日志文件给删了就行了。but where is 日志文件?,看到上面的提示,很清楚的说之前已经有文件了,顺着网站进去,发现也没有提供怎样删除。

后来,在一篇文章中讲到,删除日志文件的方法,看到他是在mysql目录下找到的,顺着这个思路找到我的mysql目录在/var/lib/mysql下,赶紧执行命令ls,发正是在它下面有日志文件 ,然后执行操作:

    [root@tserver mysql]# rm ibdata1  ib_logfile0  ib_logfile1 
    rm: remove regular file `ibdata1'? yes      
    rm: remove regular file `ib_logfile0'? yes
    rm: remove regular file `ib_logfile1'? yes

重启MariaDB服务就行了。

本来是Centos 7.3的系统 启动MariaDB的方式应该是

    systemctl start mariadb #启动服务

但是现在就变成这样的启动方式:

    service mysql start

不知道何解。。。。。。。。。。。

下一步继续执行命令

    mysql_secure_installation

这一步我在输入密码的时候还是原来的密码,输入密码一直Y就ok了。

  • 配置集群的时候发现没有wserp.cnf 在其他电脑上复制后无法识别,是因为没有权限,执行一下命令:

      chmod 777 /etc/my.cnf.d/wsrep.cnf

成功识别。

参考链接:http://www.linuxidc.com/Linux/2014-05/102229.htm

转载于:https://www.cnblogs.com/esileme/p/7606711.html

  • 1
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值