From owner-freebsd-questions@FreeBSD.ORG Thu Mar 18 01:16:25 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7EA9C16A4CE for ; Thu, 18 Mar 2004 01:16:25 -0800 (PST) Received: from web40606.mail.yahoo.com (web40606.mail.yahoo.com [66.218.78.143]) by mx1.FreeBSD.org (Postfix) with SMTP id 61C6543D2D for ; Thu, 18 Mar 2004 01:16:25 -0800 (PST) (envelope-from pjn0211@yahoo.com) Message-ID: <20040318091625.70118.qmail@web40606.mail.yahoo.com> Received: from [202.183.248.166] by web40606.mail.yahoo.com via HTTP; Thu, 18 Mar 2004 09:16:25 GMT Date: Thu, 18 Mar 2004 09:16:25 +0000 (GMT) From: =?iso-8859-1?q?Supote=20Leelasupphakorn?= To: Gareth Bailey In-Reply-To: <001c01c40cbe$b6fa6800$0500a8c0@BAILEY> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit cc: questions@freebsd.org Subject: Re: MYSQL startup error X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 18 Mar 2004 09:16:25 -0000 --- Gareth Bailey wrote: > I am running 5.2 Release, and have recently installed > mysql-4.0.18 server. I > first made a default install by issuing the following commands > in the port: > > $ make > # make install > $ cd /var/db/mysql && mysql_db_install > > Worked perfectly when i started up with: > $ mysqld_safe & > > Then i decided i wanted to reinstall with DB_DIR=/usr/db/mysql > I made deinstall and clean in the port. I removed the /var/db > directory > manually. I then did the following in an attempt to install > the DB_DIR in > /usr/db/mysql: > > # mkdir /usr/db/mysql > # chown -R mysql /usr/db > #chgrp -R mysql /usr/db > $ make DB_DIR=/usr/db/mysql > # make DB_DIR=/usr/db/mysql install > > I encountered the following two problems: > > 1. Crontab complained with the following message: > > "mkdir: /var/db/entropy: Permission denied > /usr/libexec/save-entropy[45954]: The entropy directory > /var/db/entropy does > not exist, and cannot be created. Therefore no entropy can be > saved." > > I solved this by creating /var/db/entropy and chowned and > chgrped to mysql > (don't know if that was right.) > > 2. I can't start mysqld_safe using command 'mysqld_safe &'. I > get the > following errors... > > when i try as normal user: > "/usr/local/bin/mysqld_safe: cannot create > /usr/db/mysql/server.err: > Permission denied" > > when i try from root: > "server# Starting mysqld daemon with databases from > /usr/db/mysql > 040318 09:51:58 mysqld ended" > > I had a look at server.err in /usr/db/mysql and i found the > following line: > > "040318 9:51:56 Fatal error: Can't open privilege tables: > Can't find file: > './mysql/host.frm' (errno: 13)" > > Please advise. Any assistance will be very much appreciated. > Thank you > Gareth After you re-install, have you run the script: mysql_db_install again ? That script is for prepare core database in data directory (in this case is /usr/db/mysql) and then don't forget to chown and chgrp /usr/db/mysql as well. ________________________________________________________________________ Yahoo! Messenger - Communicate instantly..."Ping" your friends today! Download Messenger Now http://uk.messenger.yahoo.com/download/index.html