Moving MySQL data to another location
If you want to move the MySQL data directory to another location, you cannot just copy the data from one directory to another. You also have to change a number of settings in both the MySQL Administrator and the my.ini file.
Stop DataMiner.
In MySQL Administrator, do the following:
Go to Service Control and stop the MySQL service.
Go to Startup Variables and write down the contents of both the Base directory and Data directory boxes.
If the data has to be moved to a folder that does not exist yet, then create that folder.
Copy all data in the current data directory to the folder that will become the new data directory.
In my.ini, located in the base directory, change the datadir parameter. If your current data directory is
C:\MySQLData
, look for the following line:datadir="C:\MySQLData\
In MySQL Administrator, do the following:
Go to Startup Variables and enter the new data directory in the Data directory box.
Go to Service Control and start the MySQL service.
Start DataMiner.
Check all trend data to make sure the move was successful.