[root@localhost]# /usr/bin/mysqld_safe &
[1] 25653
[root@localhost]# Starting mysqld daemon with databases from /var/lib/mysql
STOPPING server from pid file /var/run/mysqld/mysqld.pid
100126 03:43:33
[1]+
[root@localhost]# more /var/log/mysqld.log
100126 03:43:33
100126
InnoDB: Starting crash recovery.
InnoDB: Reading tablespace information from the .ibd files...
InnoDB: Restoring possible half-written data pages from the doublewrite
InnoDB: buffer...
100126
InnoDB: log sequence number 0 43634.
InnoDB: Doing recovery: scanned up to log sequence number 0 43634
100126
100126
100126
100126 03:43:33
执行以下命令即可:
[root@localhost]# mysql_install_db
090517 13:34:15 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it.
090517 13:34:15 [ERROR] Fatal error: Can't open and lock privilege tables: Table 'mysql.host' doesn't exist
090517 13:34:15 mysqld_safe mysqld from pid file /usr/local/mysql/var/mail.bmitwap.com.pid ended
090517 13:38:35 mysqld_safe Starting mysqld daemon with databases from /usr/local/mysql/var
shell> scripts/mysql_install_db --user=mysql --datadir=/usr/local/mysql/var
这样问题就解决了。