Iam trying to change data directory in mariadb, after changing data dir path in the ini file, then try to restart the service, it couldn't start!!! Show a warning like :
> Error 1067: The process terminated unexpectedly
In MySQL, the data dir changing is working perfectly. But I don't know why the same is not working with mariadb
.
Only the default path is working...
I should mention wonderful System internals tools (e.g procmon), which would be very helpful not only in this situation but also in many others. Windows error log is a second tool that is really-really helpful, if you'd take a look into it.Know you tools
Now to specific advice for this case - user who runs MariaDB service should be able to create file in the datadir directory. By default, MariaDB uses Network Service, while MySQL is using the Local System (most powerful Windows user).
This change makes MariaDB more secure (less impact if service is hacked), however you should not expect that NetworkService has read-write access to any directory, like LocalSystem has.
So to fix your problem, you either to make the directory writable for NetworkService, or change service user to one that has read-write access to the directory.