Oh yes there is.
For one thing, I am not a big fan of using .msi for MySQL.
I like doing the following to create a full Windows service without using .msi
01) Download the no-install zip of MySQL to your desktop.
02) Open the Zip File in Window1. You should see the data folder, bin folder, several my.ini files and other files.
03) Create a Server Folder and a Data Folder in a Desired Location. For this example, in a DOS Window, do the following :
md C:\MySQLServer
md C:\MySQLData
04) Open C:\MySQLServer
in Window Explorer (Window2)
05) Copy and Paste the Zip Contents (Window1) into the C:\MySQLServer (Window2)
06) Open C:\MySQLServer\data
in Windows Explorer (Window3)
07) Open C:\MySQLData
in Window Explorer (Window4)
08) Copy and Paste the Contents of C:\MySQLServer\data
(Window3) into C:\MySQLData
(Window4)
09) Close Window3 and Window4
10) Open a DOS Window and run the following DOS commands
cd C:\MySQLServer
copy my-medium.ini my.ini
notepad my.ini
define datadir="C:\\MySQLData"
cd C:\MySQLServer\bin
mysqld --install MySQLNew
net start MySQLNew
11) Close all Windows
You should be done !!!
Let us know how it turned out !!!
BTW The service name turns out as MySQLNew
Generally speaking this is a bad idea. Database software need tight control of the files they use (for obvious reasons). If you put your database files on NTFS on Linux, you're asking for trouble.
Write support for NTFS on Linux is (afaik) still rather experimental. I have no idea how well-behaved file locking is on this combination.
My advice would be to export the database from windows using mysqldump
or something like that, and rebuild the database on the linux side using that dump - with the data on a native filesystem (ext, xfs, reiserfs, ... whatever you feel is best).
Best Answer
Yes. Have a look at this document:
http://dev.mysql.com/doc/refman/5.1/en/windows-create-option-file.html
You can specify the data folder either in an option file, or on the command-line for the service.
Edit: I just pulled down the MSI and had a look, and I don't see any way to specify the data directory during install w/ an addt'l property on the command line.
You can transform the install with Orca, if you are familiar with Windows Installer, to change the "DataDir" location in the Directory table.