Bug #113610 Cannot relocate MySQL Data Directory
Submitted: 10 Jan 2024 16:26 Modified: 11 Jan 2024 15:07
Reporter: Craig Anderson Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Server Severity:S2 (Serious)
Version:8.2.0 OS:Windows (Server 2022)
Assigned to: CPU Architecture:Any
Tags: 64 bit mysql

[10 Jan 2024 16:26] Craig Anderson
Description:
I have a small C: and large E:, want to migrate MySQL data to E:
Install via .msi
It works.
Stop service.
Change datadir in my.ini to E:/MySQL/Data
Move data files to it.
Start service.
Service stops with no explanation.
It does update dev.err (server's name is dev) in the moved directory, so it knows what I want, just won't do it!
Move data dir back to original location and it works again.

How to repeat:
See above description

Suggested fix:
Unknown. There is probably one or more spots in the code that look for the default location without checking the datadir setting.
[11 Jan 2024 12:42] MySQL Verification Team
Hello Craig Anderson,

Thank you for the bug report.
Imho this is duplicate of Bug #89991, please see Bug #89991.

Regards,
Ashwini Patil
[11 Jan 2024 15:07] Craig Anderson
Yes! The account NETWORK SERVICES must have full access to the data directory.
Thank you