所以我用 mysql -hlocalhost -uroot -p
报错误 eeror 2002(HY000) can't connect to local myslq serer. through socket '/var/lib/mysql/mysql.sock'
换--protocal=tcp 还是抱mysql.sock错误
这个很奇怪 ,为 什么mysql下面会没哟数据或者目录啦?? (安装没有报错误 )作者: liyihongcug 时间: 2009-6-24 16:36
/var/log/mysqld.log
its content is like this:
090603 17:21:48 mysqld ended
090622 22:00:59 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
090622 22:00:59 [Warning] The syntax 'for replication startup options' is deprecated and will be removed in MySQL 5.2. Please use 'CHANGE MASTER' instead.
/usr/sbin/mysqld: Table 'mysql.plugin' doesn't exist
090622 22:00:59 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it.
InnoDB: The log sequence number in ibdata files does not match
InnoDB: the log sequence number in the ib_logfiles!
090622 22:00:59 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...
090622 22:00:59 InnoDB: Started; log sequence number 0 46409
090622 22:00:59 [ERROR] Fatal error: Can't open and lock privilege tables: Table 'mysql.host' doesn't exist
090622 22:00:59 mysqld_safe mysqld from pid file /var/lib/mysql/localhost.localdomain.pid ended
090623 15:21:43 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
090623 15:21:45 [Warning] The syntax 'for replication startup options' is deprecated and will be removed in MySQL 5.2. Please use 'CHANGE MASTER' instead.
/usr/sbin/mysqld: Table 'mysql.plugin' doesn't exist
090623 15:21:45 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it.
InnoDB: The log sequence number in ibdata files does not match
InnoDB: the log sequence number in the ib_logfiles!
090623 15:21:46 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...
090623 15:21:47 InnoDB: Started; log sequence number 0 46409
090623 15:21:47 [ERROR] Fatal error: Can't open and lock privilege tables: Table 'mysql.host' doesn't exist
090623 15:21:47 mysqld_safe mysqld from pid file /var/lib/mysql/localhost.localdomain.pid ended
090623 20:33:27 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
090623 20:33:28 [Warning] The syntax 'for replication startup options' is deprecated and will be removed in MySQL 5.2. Please use 'CHANGE MASTER' instead.
/usr/sbin/mysqld: Table 'mysql.plugin' doesn't exist
090623 20:33:28 [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it.
InnoDB: The log sequence number in ibdata files does not match
InnoDB: the log sequence number in the ib_logfiles!
090623 20:33:28 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...
090623 20:33:29 InnoDB: Started; log sequence number 0 46409
090623 20:33:29 [ERROR] Fatal error: Can't open and lock privilege tables: Table 'mysql.host' doesn't exist
090623 20:33:29 mysqld_safe mysqld from pid file /var/lib/mysql/localhost.localdomain.pid ended作者: kider 时间: 2009-6-24 17:38
没有生成mysql系统库,重新卸载、安装MySQL rpm 包