MySQL data drive designation

User, date Message
debh Written by debh
6 years ago
Category: General
6 posts since Mon, 09 Jun 08
I have MySql and the Data installed on the D drive of my server. It is running low on disk space. I would like to start using another set of drives for additional space however, they will be set as another drive letter, E. Is it possible to have MySql look at data on 2 drive letters. My ini file, c:\windows\my.ini notes the following:

#language=C:/mysql/share/your language directory
#slow query log#=

Would I add more info to the datadir line?

rosenfield Written by rosenfield
6 years ago
127 posts since Wed, 24 Jan 07
Sort of - you can have different databases within the same server reside on different partitions, but you cannot split a single database across partitions AFAIK.

For each database you want to put on E:\, create a .sym file instead of the database directory, as described in:

The .sym file should just contain the name of a folder on E:\.

If you're using InnoDB rather than the MyISAM engine, things are slightly more complicated. InnoDB per default uses a shared tablespace outside of the database directories. It's not impossible though, you just have to enable --innodb_file_per_table:
debh Written by debh
6 years ago
6 posts since Mon, 09 Jun 08
Will this work for 3.5 version? I think what you are saying, I have 2 databases, d:\mysql\data\database and d:\mysql\data\database2. I should copy the d:\mysql\data\database2 to E. On D, I will have d:\mysql\data\database and d:\mysql\data\database2.sym file. This sym file will contain the path to e:\mysql\data\database2.
ansgar Written by ansgar
6 years ago
5098 posts since Fri, 07 Apr 06
There is no 3.5 version of MySQL?
debh Written by debh
6 years ago
6 posts since Mon, 09 Jun 08
I apologize. It is version 3.23.51-nt.

Please login to leave a reply, or register at first.