cloudera manager运维日志 2018.02.26

登陆上cloudera manager 发现很多报空间不足,手贱就将/tmp目录全部删除了,然后重启server和agent,发现agent可以正常启动,但是server没办法正常启动,查看日志,发现报错

2018-02-23 11:13:05,313 ERRORmain:com.cloudera.enterprise.dbutil.DbUtil: InnoDB engine not found. Showengines reported: [MRG_MYISAM, CSV, MyISAM, MEMORY]

2018-02-23 11:13:05,313 ERRORmain:com.cloudera.server.cmf.bootstrap.EntityManagerFactoryBean: InnoDb engineisn't present or enabled. SCM requires InnoDb MySQL db engine.

日志的意思是找不到mysqlInnoDB这个引擎,于是登录mysql(mysql -u root -p),使用命令 show engines;结果如下:

+------------+---------+-----------------------------------------------------------+--------------+------+------------+

| Engine    | Support | Comment                                                  | Transactions | XA   | Savepoints|

+------------+---------+-----------------------------------------------------------+--------------+------+------------+

| MRG_MYISAM | YES     | Collection of identical MyISAMtables                     | NO           | NO   | NO        |

| CSV       | YES     | CSV storage engine                                        |NO           | NO   | NO        |

| MyISAM    | DEFAULT | Default engine as of MySQL 3.23 with great performance    | NO           | NO   | NO        |

| MEMORY    | YES     | Hash based, stored inmemory, useful for temporary tables | NO           | NO   | NO        |

+------------+---------+-----------------------------------------------------------+--------------+------+------------+

确实没有InnoDB引擎,怀疑是没有正常启动,于是退出mysql,重启mysqld服务(servicemysqld restart),重新进入mysql,发现还是原来的样子

 

于是

        首先确定,在mysql的'plugin_dir'下有ha_innodb_plugin.so和ha_innodb.so两个文件 

查询'plugin_dir'的路径可以用以下命令 

mysql> show variables like'plugin_dir'; 

+---------------+-------------------------+

| Variable_name | Value                   |

+---------------+-------------------------+

| plugin_dir    |/usr/lib64/mysql/plugin |

+---------------+-------------------------+

1 row in set (0.01 sec) 

 

如果没有找到,在mysql编译目录里有下面的目录文件(内置的innodb和innodb_plugin) 

 

storage/innobase/.libs/ha_innodb.so 

 

storage/innodb_plugin/.libs/ha_innodb_plugin.so 

 

您需要把它们(ha_innodb_plugin.so和ha_innodb.so)拷贝到mysql的plugin目录中

 

接下来就是在mysql命令行安装一下 

# mysql 

Welcome to the MySQL monitor.  Commands end with; or \g. 

Your MySQL connection id is 18 

Server version: 5.1.36-log Source distribution 

Type 'help;' or '\h' for help. Type '\c' to clear the current inputstatement. 

mysql> show engines; 

接下来就是在mysql命令行安装一下 

# mysql 

Welcome to the MySQL monitor.  Commands end with; or \g. 

Your MySQL connection id is 18 

Server version: 5.1.36-log Source distribution 

Type 'help;' or '\h' for help. Type '\c' to clear the current inputstatement. 

mysql> show engines; 

+------------+---------+-----------------------------------------------------------+--------------+------+------------+ 

|Engine     | Support |Comment                                                  | Transactions | XA   | Savepoints | 

+------------+---------+-----------------------------------------------------------+--------------+------+------------+ 

| MRG_MYISAM |YES     | Collection of identical MyISAMtables                    | NO           |NO   | NO         | 

|CSV        | YES     |CSV storageengine                                       | NO           |NO   | NO         | 

|MEMORY     | YES     | Hash based,stored in memory, useful for temporary tables |NO           | NO  | NO         | 

|MyISAM     | DEFAULT | Default engine as of MySQL 3.23 withgreat performance    |NO           | NO  | NO         | 

+------------+---------+-----------------------------------------------------------+--------------+------+------------+ 

4 rows in set (0.00 sec) 

mysql> INSTALL PLUGIN InnoDB SONAME 'ha_innodb_plugin.so'; 

Query OK, 0 rows affected (0.69 sec) 

mysql> show engines; 

5 rows in set (0.00 sec) 

 

来自 <http://blog.csdn.net/chengxuyuanyonghu/article/details/46834041>

 

4 rows in set (0.00 sec) 

mysql> INSTALL PLUGIN InnoDB SONAME'ha_innodb.so'; 

Query OK, 0 rows affected (0.69 sec) 

mysql> show engines; 

+------------+---------+------------------------------------------------------------+--------------+------+------------+

| Engine    | Support | Comment                                                   | Transactions | XA   | Savepoints|

+------------+---------+------------------------------------------------------------+--------------+------+------------+

| InnoDB    | YES     | Supports transactions,row-level locking, and foreign keys | YES          | YES | YES        |

| CSV       | YES     | CSV storageengine                                        | NO           | NO   | NO        |

| MyISAM    | DEFAULT | Default engine as of MySQL 3.23 with great performance     | NO           | NO   | NO        |

| MRG_MYISAM | YES     | Collection of identical MyISAMtables                      | NO           | NO   | NO        |

| MEMORY    | YES     | Hash based, stored inmemory, useful for temporary tables  |NO           | NO   | NO        |

+------------+---------+------------------------------------------------------------+--------------+------+------------+

 

5 rows in set (0.00 sec) 

 


你可能感兴趣的:(运维日志,cloudera,agent,server,运维)