Date: Tue, 14 Jun 2005 14:21:09 +0300 From: Tsampros Leonidas <ltsampros@upnet.gr> To: Gerard Seibert <gerard-seibert@suscom.net>, freebsd-questions@freebsd.org Subject: Re: Starting MySQL at bootup Message-ID: <42AEBDA5.2000107@upnet.gr> In-Reply-To: <Pine.WNT.4.63.0506140708580.3092@Treneq> References: <Pine.WNT.4.63.0506140708580.3092@Treneq>
next in thread | previous in thread | raw e-mail | index | archive | help
Gerard Seibert wrote: > This is probably a dumb question, but I will ask it anyway. > > I have 'mysql' installed. From what I have deduced from the > documentation, I should start it using 'mysqld_safe'. I am assuming that > I would use the syntax 'mysqld_safe &' to force the program into the > background upon starting. What I can not seem to figure out is how to > get the program to start automatically upon boot up. > Usually, when you install a service such mysql from the ports collection all of it's files are installed with --prefix=/usr/local . That means that the usual startup scripts and configuration files are installed at /usr/local/etc . Taking a look at the file /usr/local/etc/rc.d/mysql-server.sh , you'll see enough comments on how to configure your system , to start mysql automatically upon boot up. <from mysql-server.sh> # Add the following line to /etc/rc.conf to enable mysql: # mysql_enable (bool): Set to "NO" by default. # Set it to "YES" to enable MySQL. # mysql_limits (bool): Set to "NO" by default. # Set it to yes to run `limits -e -U mysql` # just before mysql starts. # mysql_dbdir (str): Default to "/var/db/mysql" # Base database directory. # mysql_args (str): Custom additional arguments to be passed # to mysqld_safe (default empty). </from mysql-server.sh> This is the entries i have in my /etc/rc.conf file : mysql_enable="YES" #mysql_dbdir="/usr/local/data" #mysql_args="--log=/var/log/mysql.log "
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?42AEBDA5.2000107>