mysqld won"t start

mysqld won"t start

am 22.10.2007 14:29:32 von Bart Vandewoestyne

After an upgrade to the latest Debian stable it seems like my
mysqld won't start:

forsythe:~# /etc/init.d/mysql restart
Stopping MySQL database server: mysqld.
Starting MySQL database server: mysqld . . . . . . . . . . . . . . failed!

In /var/log/daemon.log, I find the following which is probably related to
this problem:

Oct 22 14:23:42 forsythe mysqld_safe[11648]: started
Oct 22 14:23:44 forsythe mysqld[11651]: 071022 14:23:44 InnoDB: Started; log sequence number 0 43912
Oct 22 14:23:44 forsythe mysqld[11651]: 071022 14:23:44 [Note] Recovering after a crash using /var/log/mysql/mysql-bin
Oct 22 14:23:44 forsythe mysqld[11651]: 071022 14:23:44 [Note] Starting crash recovery...
Oct 22 14:23:44 forsythe mysqld[11651]: 071022 14:23:44 [Note] Crash recovery finished.
Oct 22 14:23:44 forsythe mysqld[11651]: 071022 14:23:44 [ERROR] Fatal error: Can't open and lock privilege tables: Can't find file: 'host' (errno: 2)
Oct 22 14:23:44 forsythe mysqld_safe[11671]: ended
Oct 22 14:23:59 forsythe /etc/init.d/mysql[11798]: 0 processes alive and '/usr/bin/mysqladmin --defaults-file=/etc/mysql/debian.cnf ping' resulted in
Oct 22 14:23:59 forsythe /etc/init.d/mysql[11798]: ^G/usr/bin/mysqladmin: connect to server at 'localhost' failed
Oct 22 14:23:59 forsythe /etc/init.d/mysql[11798]: error: 'Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)'
Oct 22 14:23:59 forsythe /etc/init.d/mysql[11798]: Check that mysqld is running and that the socket: '/var/run/mysqld/mysqld.sock' exists!

Mind the line:

Oct 22 14:23:44 forsythe mysqld[11651]: 071022 14:23:44 [ERROR] Fatal error: Can't open and lock privilege tables: Can't find file: 'host' (errno: 2)

which is probably the main problem here...

I have found the following Debian bug report:

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=345895

The reason for the problem mentioned there is that this happens when
older and unsupported ISAM tables are used instead of MyISAM tables.

However, I have the impression that I *am* using MyISAM tables, because
in for example the directory /var/lib/mysql/mysql all the files have the
extensions .frm, .MYD and .MYI. For the 'host' file however, i only have
and .frm file:

forsythe:/var/lib/mysql/mysql# ls -al host*
-rw-rw---- 1 mysql mysql 9416 Jul 23 19:42 host.frm

Could the fact that there is no .MYD and .MYI file be causing my problem?

If 'yes', what can I do to solve this? If 'no', then how can I solve my
problem and be able to start mysqld again?

Thanks,
Bart

--
"Share what you know. Learn what you don't."