MYSQL 启动报错!

在做测试时 我将mysql的数据库的目录给更换后 在用mysqld_safe 启动mysql时无法启动错误日志:

130711 09:56:40 mysqld_safe mysqld from pid file /home/data//lmlq.cn.gongchang.cn.pid ended
 Can't open the mysql.plugin table130711 09:58:51 mysqld_safe Starting mysqld daemon with databases from /home/data/
tcmalloc: large alloc 2842464256 bytes == (nil) @
tcmalloc: large alloc 2131845120 bytes == 0x10d4a000 @
/usr/local/mysql/libexec/mysqld: Table 'mysql.plugin' doesn't exist
130711  9:58:53 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it.

不存在'mysql.plugin' 看了下官方文档如下:

The mysql_plugin utility enables MySQL administrators to manage which plugins a MySQL server loads. It provides an alternative to manually specifying the --plugin-load option at server startup or using the INSTALL PLUGIN and UNINSTALL PLUGIN statements at runtime. mysql_plugin is available as of MySQL 5.5.16. 简单的说 mysql_plugin 是为mysql管理员去管理那个插件被mysql服务器加载了。

可以使用:

/usr/local/mysql/bin/mysql_install_db  --user=mysql --datadir=/home/data/ 来初始化。

 

 

你可能感兴趣的:(MYSQL 启动报错!)