Click to See Complete Forum and Search --> : mysql doesn't start


davers
09-15-2002, 05:10 PM
I can't get mysql to run on slakware 8.0. I ran mysql_install_db and I'm trying to run /usr/bin/safe_mysqld, but safe_mysqld ends after a couple of seconds. This is what is outputted to my /var/lib/mysql/davemon.err file:

020915 22:00:20 mysqld started
020915 22:00:20 /usr/libexec/mysqld: Can't find file: './mysql/host.frm' (errno: 13)
020915 22:00:20 mysqld ended

When I look in /var/lib/mysql/mysql, there is a host.frm file present. When I do safe_mysqld --help, it outputs the following:

basedir: /usr/
datadir: /var/lib/mysql/
tmpdir: /tmp/
language: /usr/share/mysql/english/
pid file: /var/lib/mysql/davemon.pid
TCP port: 3306
Unix socket: /var/run/mysql/mysql.sock

(davemon is my host name). I've read that people reccomend downloading the source version of mysql from mysql.com, instead of attempting to install the version that comes with slakware, but that's not possible for me. Can anyone help?

-Dave

bdl
09-15-2002, 06:10 PM
The host.frm file should be under '/var/lib/mysql/mysql'. The 'datadir' is '/var/lib/mysql' and the database 'mysql' should be under '/var/lib/mysql/mysql'.Hope this helps!

davers
09-15-2002, 09:12 PM
Original post had some mistakes, so I edited to make more sense. Here is the complete shell output of my problem:

root@davemon:/var/lib/mysql# ls
davemon.err mysql test
root@davemon:/var/lib/mysql# ls mysql/
columns_priv.MYD db.MYD func.MYD host.MYD tables_priv.MYD user.MYD
columns_priv.MYI db.MYI func.MYI host.MYI tables_priv.MYI user.MYI
columns_priv.frm db.frm func.frm host.frm tables_priv.frm user.frm
root@davemon:/var/lib/mysql# safe_mysqld
Starting mysqld daemon with databases from /var/lib/mysql
020916 02:08:40 mysqld ended

root@davemon:/var/lib/mysql# tail -n 5 /var/lib/mysql/davemon.err

020916 02:08:40 mysqld started
020916 2:08:40 /usr/libexec/mysqld: Can't find file: './mysql/host.frm' (errno: 13)
020916 02:08:40 mysqld ended

Even when I set the data directory explicitly using
safe_mysqld --data /var/lib/mysql it still can't find it :(

-Dave

dokks
09-16-2002, 03:14 PM
Try adding -user=root for a test run ....and the above poster is correct.

The host.frm file should be under '/var/lib/mysql/mysql'.

davers
09-17-2002, 04:19 PM
Thanks, all working now :)
- Dave.