免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 2864 | 回复: 3
打印 上一主题 下一主题

linux安装mysql5.5.18后无法启动 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2014-08-03 19:05 |只看该作者 |倒序浏览
系统为centos5.5 mysql为5.5.18(mysql官方下载)


cmake . -DCMAKE_INSTALL_PREFIX=/usr/local/mysql -DMYSQL_DATADIR=/data/mysql -DSYSCONFDIR=/usr/local/etc/ -DWITH_BLACKHOLE_STORAGE_ENGINE=1


编辑 /etc/rc.d/init.d/mysqld
basedir=/usr/local/mysql
datadir=/data/mysql
编辑配置文件 /usr/local/etc/my.cnf,
[mysqld]
datadir = /data/mysql
wait-timeout = 10
max_connections = 512
max_connect_errors = 10000000
local-infile=0
max_allowed_packet = 16M
thread_cache_size = 8

后运行
service mysqld start

提示Starting MySQL.The server quit without updating PID file (/data/mysql/localhost.localdomain.pid).[失败]

error日志:

140803 18:37:56 mysqld_safe Starting mysqld daemon with databases from /usr/local/mysql/data/mysql
140803 18:37:56 [Warning] The syntax '--log' is deprecated and will be removed in a future release. Please use '--general-log'/'--general-log-file' instead.
140803 18:37:56 [Warning] The syntax '--log-slow-queries' is deprecated and will be removed in a future release. Please use '--slow-query-log'/'--slow-query-log-file' instead.
/usr/local/mysql/bin/mysqld: Table 'mysql.plugin' doesn't exist
140803 18:37:56 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it.
140803 18:37:56 InnoDB: The InnoDB memory heap is disabled
140803 18:37:56 InnoDB: Mutexes and rw_locks use InnoDB's own implementation
140803 18:37:56 InnoDB: Compressed tables use zlib 1.2.3
140803 18:37:56 InnoDB: Initializing buffer pool, size = 128.0M
140803 18:37:56 InnoDB: Completed initialization of buffer pool
140803 18:37:56 InnoDB: highest supported file format is Barracuda.
InnoDB: The log sequence number in ibdata files does not match
InnoDB: the log sequence number in the ib_logfiles!
140803 18:37:56  InnoDB: Database was not shut down normally!
InnoDB: Starting crash recovery.
InnoDB: Reading tablespace information from the .ibd files...
InnoDB: Restoring possible half-written data pages from the doublewrite
140803 18:37:56 mysqld_safe Starting mysqld daemon with databases from /usr/local/mysql/data/mysql
140803 18:37:56 [Warning] The syntax '--log' is deprecated and will be removed in a future release. Please use '--general-log'/'--general-log-file' instead.
140803 18:37:56 [Warning] The syntax '--log-slow-queries' is deprecated and will be removed in a future release. Please use '--slow-query-log'/'--slow-query-log-file' instead.
/usr/local/mysql/bin/mysqld: Table 'mysql.plugin' doesn't exist
140803 18:37:56 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it.
140803 18:37:56 InnoDB: The InnoDB memory heap is disabled
140803 18:37:56 InnoDB: Mutexes and rw_locks use InnoDB's own implementation
140803 18:37:56 InnoDB: Compressed tables use zlib 1.2.3
140803 18:37:56 InnoDB: Initializing buffer pool, size = 128.0M
140803 18:37:56 InnoDB: Completed initialization of buffer pool
140803 18:37:56 InnoDB: highest supported file format is Barracuda.
InnoDB: The log sequence number in ibdata files does not match
InnoDB: the log sequence number in the ib_logfiles!
140803 18:37:56  InnoDB: Database was not shut down normally!
InnoDB: Starting crash recovery.
InnoDB: Reading tablespace information from the .ibd files...
InnoDB: Restoring possible half-written data pages from the doublewrite
InnoDB: buffer...
140803 18:37:56  InnoDB: Waiting for the background threads to start
140803 18:37:57 InnoDB: 1.1.8 started; log sequence number 1595675
^G/usr/local/mysql/bin/mysqld: File '/usr/local/mysql/log/slowquery.log' not found (Errcode: 13)
140803 18:37:57 [ERROR] Could not use /usr/local/mysql/log/slowquery.log for logging (error 13). Turning logging off for the whole duration of the MySQL server process. To turn it on again: fix the cause, shutdown the MySQL server and restart it.
^G/usr/local/mysql/bin/mysqld: File '/usr/local/mysql/log/mysql.log' not found (Errcode: 13)
140803 18:37:57 [ERROR] Could not use /usr/local/mysql/log/mysql.log for logging (error 13). Turning logging off for the whole duration of the MySQL server process. To turn it on again: fix the cause, shutdown the MySQL server and restart it.
140803 18:37:57 [Note] Recovering after a crash using mysql-bin
140803 18:37:57 [Note] Starting crash recovery...
140803 18:37:57 [Note] Crash recovery finished.
140803 18:37:57 [ERROR] Fatal error: Can't open and lock privilege tables: Table 'mysql.host' doesn't exist
140803 18:37:57 mysqld_safe mysqld from pid file /usr/local/mysql/data/mysql/localhost.localdomain.pid ended

论坛徽章:
1
巳蛇
日期:2014-08-21 15:09:09
2 [报告]
发表于 2014-08-08 13:29 |只看该作者
140803 18:37:57 [ERROR] Fatal error: Can't open and lock privilege tables: Table 'mysql.host' doesn't exist


问题已经说明了。

论坛徽章:
0
3 [报告]
发表于 2014-08-08 14:20 |只看该作者
应该先解决这个吧
140803 18:37:56 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it.

论坛徽章:
381
CU十二周年纪念徽章
日期:2014-01-04 22:46:58CU大牛徽章
日期:2013-03-13 15:32:35CU大牛徽章
日期:2013-03-13 15:38:15CU大牛徽章
日期:2013-03-13 15:38:52CU大牛徽章
日期:2013-03-14 14:08:55CU大牛徽章
日期:2013-04-17 11:17:19CU大牛徽章
日期:2013-04-17 11:17:32CU大牛徽章
日期:2013-04-17 11:17:37CU大牛徽章
日期:2013-04-17 11:17:42CU大牛徽章
日期:2013-04-17 11:17:47CU大牛徽章
日期:2013-04-17 11:17:52CU大牛徽章
日期:2013-04-17 11:17:56
4 [报告]
发表于 2014-08-08 22:27 |只看该作者
有个mysql的初始化数据库的命令,记不清了,需要运行下,创建mysql数据库以及里面的表
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP