启动Mysql5.5时提示如下错误:
Starting MySQL.. ERROR! The server quit without updating PID file (/var/lib/mysql/MyCloudServer.pid).
打开/var/log/mysqld.log日志目录查看日志,错误如下:
[root@MyCloudServer ~]# cat /var/log/mysqld.log 150703 13:45:11 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql /usr/sbin/mysqld: error while loading shared libraries: libaio.so.1: cannot open shared object file: No such file or directory 150703 13:45:11 mysqld_safe mysqld from pid file /var/lib/mysql/MyCloudServer.pid ended
安装好mysql发现无法启动查看日志,提示:加载共享库时出错xxxxxxxxxxxx 缺少libaio
安装libaio
yum install libaio
启动再次出现如下错误:
InnoDB: Foreign key constraint system tables created 150703 13:48:26 InnoDB: Waiting for the background threads to start 150703 13:48:27 InnoDB: 5.5.30 started; log sequence number 0 150703 13:48:27 [Note] Server hostname (bind-address): '0.0.0.0'; port: 3306 150703 13:48:27 [Note] - '0.0.0.0' resolves to '0.0.0.0'; 150703 13:48:27 [Note] Server socket created on IP: '0.0.0.0'. 150703 13:48:27 [ERROR] Fatal error: Can't open and lock privilege tables: Table 'mysql.host' doesn't exist 150703 13:48:27 mysqld_safe mysqld from pid file /var/lib/mysql/MyCloudServer.pid ended
初始化数据库
mysql_install_db
初始化数据库后启动发现已经可以启动,同时我们也不要忘记了df -h看看是不是根目录占用100%了或数据盘。
本教程由铁网维原创出品 服务器运维官方网址http://www.tieww.com 欢迎大家多多关注本站 感谢大家的支持。