VPS侦探论坛

 找回密码
 注册
查看: 6095|回复: 4

使用my-innodb-heavy-4g.chf 后mysql无法启动

[复制链接]
发表于 2014-7-24 14:13:02 | 显示全部楼层 |阅读模式

军哥,帮我找找错误原因,我恢复到原来的的my.cnf也还是同样问题。

140724 13:04:32 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
140724 13:04:32 [ERROR] Can't find messagefile '/usr/share/mysql/errmsg.sys'
/usr/local/mysql/bin/mysqld: Unknown error 1146
140724 13:04:32 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it.
140724 13:04:32 InnoDB: The InnoDB memory heap is disabled
140724 13:04:32 InnoDB: Mutexes and rw_locks use GCC atomic builtins
140724 13:04:32 InnoDB: Compressed tables use zlib 1.2.7
140724 13:04:32 InnoDB: Initializing buffer pool, size = 4.0G
140724 13:04:32 InnoDB: Completed initialization of buffer pool
140724 13:04:32  InnoDB: Operating system error number 13 in a file operation.
InnoDB: The error means mysqld does not have the access rights to
InnoDB: the directory.
InnoDB: File name /usr/local/mysql/var/ibdata1
InnoDB: File operation call: 'create'.
InnoDB: Cannot continue operation.
140724 13:04:32 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid ended
美国VPS推荐: 遨游主机LinodeLOCVPS主机云搬瓦工80VPSVultr美国VPS主机中国VPS推荐: 阿里云腾讯云。LNMP付费服务(代装/问题排查)QQ 503228080
发表于 2014-7-24 17:19:08 | 显示全部楼层


系统里可能还有其他mysql存在
用yum或apt-get 安装的一般数据库在/var/lib/mysql
建议用rpm -qa|grep mysql 或dpkg -l|grep mysql 看一下

如果要用heavy-4g的配置文件需要将里面的一些配置要改掉
如启用了,需要修改datadir      = 还需要修改innodb_data_home_dir 和innodb_log_group_home_dir 为你数据库目录
Linux下Nginx+MySQL+PHP自动安装工具:https://lnmp.org
 楼主| 发表于 2014-7-24 18:02:11 | 显示全部楼层

我查询了下,得到这些提示


/# dpkg -l|grep mysql
ii  libdbd-mysql-perl                4.021-1+b1                 amd64        Per                l5 database interface to the MySQL database
ii  libmysqlclient18:amd64           5.5.37-0+wheezy1           amd64        MyS                QL database client library
ii  mysql-common                     5.5.37-0+wheezy1           all          MyS                QL database common files, e.g. /etc/mysql/my.cnf
# rpm -qa|grep mysql
bash: rpm: command not found
美国VPS推荐: 遨游主机LinodeLOCVPS主机云搬瓦工80VPSVultr美国VPS主机中国VPS推荐: 阿里云腾讯云。LNMP付费服务(代装/问题排查)QQ 503228080
发表于 2014-7-24 20:40:08 | 显示全部楼层

回复 3# 的帖子




apt-get remove mysql-common
然后rm -rf /etc/mysql/
再启动mysql应该就行了
Linux下Nginx+MySQL+PHP自动安装工具:https://lnmp.org
 楼主| 发表于 2014-7-31 16:23:20 | 显示全部楼层

很奇怪的是,我按照上述操作了后还是启动不了,日志文件如下:

140731 16:07:55  InnoDB: Operating system error number 13 in a file operation.
InnoDB: The error means mysqld does not have the access rights to
InnoDB: the directory.
InnoDB: File name /usr/local/mysqlar/ibdata1
InnoDB: File operation call: 'create'.
InnoDB: Cannot continue operation.
140731 16:07:55 mysqld_safe mysqld from pid file /usr/local/mysqlar/shenziyang.pid ended
140731 16:08:12 mysqld_safe Starting mysqld daemon with databases from /usr/local/mysqlar
^G/usr/local/mysql/bin/mysqld: Can't find file: './mysql/plugin.frm' (errno: 13)
140731 16:08:12 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it.
140731 16:08:12 InnoDB: The InnoDB memory heap is disabled
140731 16:08:12 InnoDB: Mutexes and rw_locks use GCC atomic builtins
140731 16:08:12 InnoDB: Compressed tables use zlib 1.2.7
140731 16:08:12 InnoDB: Initializing buffer pool, size = 4.0G
140731 16:08:13 InnoDB: Completed initialization of buffer pool
140731 16:08:13  InnoDB: Operating system error number 13 in a file operation.
InnoDB: The error means mysqld does not have the access rights to
InnoDB: the directory.
InnoDB: File name /usr/local/mysqlar/ibdata1
InnoDB: File operation call: 'create'.
InnoDB: Cannot continue operation.
140731 16:08:13 mysqld_safe mysqld from pid file /usr/local/mysqlar/shenziyang.pid ended

军哥运维代购:http://shop63846532.taobao.com/

您需要登录后才可以回帖 登录 | 注册

本版积分规则

小黑屋|手机版|Archiver|VPS侦探 ( 鲁ICP备16040043号-1 )

GMT+8, 2024-5-11 10:41 , Processed in 0.027012 second(s), 16 queries .

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表