Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 6 Feb 2002 09:39:27 -0800 (PST)
From:      Andrew Gould <andrewgould@yahoo.com>
To:        joe@jwebmedia.com, FBSD <freebsd-questions@FreeBSD.ORG>
Subject:   Re: Starting mysql on boot
Message-ID:  <20020206173927.49522.qmail@web13408.mail.yahoo.com>
In-Reply-To: <3C6156D4.682E52FA@jwebmedia.com>

next in thread | previous in thread | raw e-mail | index | archive | help
You have the correct directory.  Without more
information, however, it's hard to tell what went
wrong.

If you installed from non-port package or source code,
you'll need to initialize the database before the
server will start.  If you install from the port
system, the database initialization will be done for
you.

If you use the ports to install mysql, everything
should work fine:

1.  Install mysql server using the ports system.

2.  The databases will be installed to /var/db/mysql. 
My /var is in a slice that's too small for my database
usage; so I moved the database directory __before__
starting the server:

mv /var/db/mysql /usr/local/mysql
ln -s /usr/local/mysql /var/db/mysql

3.  The port installs example configuration files in
/usr/local/share/mysql.  You don't need to do anything
with these unless you want to change the default
configuration.  (Let's defer this discussion to
another thread.)

4.  The mysql port should have put the startup script
in /usr/local/etc/rc.d.  The server should start at
bootup.  As root, execute
'/usr/local/etc/rc.d/mysql-server.sh start' to start
the server without rebooting.

5. As a non-root system user (Don't confuse the system
'root' user with the mysql 'root' user.), set the
password for the mysql root user:

'mysqladmin -uroot password "new_password"'

You should now be ready to use the database as the
mysql root user and grant privileges to non-root
users.

Best of luck,

Andrew Gould


--- Joseph Koenig <joe@jwebmedia.com> wrote:
> Does anyone have experience with getting mysql to
> load a start up. All
> of the docs I'm finding say to just move the
> mysql.server file into
> 'your systems startup directory' - so I moved it to
> /usr/local/etc/rc.d/
> - is that the right place? If so, what am I missing?
> Thanks,
> 
> Joe
> 
> To Unsubscribe: send mail to majordomo@FreeBSD.org
> with "unsubscribe freebsd-questions" in the body of
> the message


__________________________________________________
Do You Yahoo!?
Send FREE Valentine eCards with Yahoo! Greetings!
http://greetings.yahoo.com

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020206173927.49522.qmail>