faqts : Computers : Databases : MySQL : Installation and Setup : Installation Methods : RPMs

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

27 of 33 people (82%) answered Yes
Recently 9 of 10 people (90%) answered Yes

Entry

When installing from RPMs, how can I change the directory where the database files reside?

Jan 25th, 2000 08:57
Nathan Wallace, David Coulson


With rpms, you'll have a /etc/rc.d/init.d/mysql script, which starts the
safe_mysqld binary. In this file, there is a 'datadir' variable, which
points to the directory containing the databases. Simply change this
directory path to something else (you might want to change other
references to /var/lib/mysql too, such as for the process id file and
the .err file).