I am moving a SQL Server database to a separate server from the application that uses it (currently app and SQL are on the same server).
The new instance has been configured to default data (.mdf
) and log (.ldf
) files to be stored on separate drives per what I understand is general best practice.
I went through the process of actually moving the non-master system database files (temp, model, etc.) to these locations, leaving the master for last because it uses a different process. See this link for the instructions I used: https://learn.microsoft.com/en-us/sql/relational-databases/databases/move-system-databases?view=sql-server-ver16
For the master database, the instructions say that after moving it, you should update the SQLDataRoot
value in the registry to point to the location of the "master database files", but since the data and log files are now in separate folders, I wasn't sure what location to specify. From there, I wondered more broadly if I should even be separating them, or if they should always remain together, and only new databases have their data and log files moved to separate drives.
I haven't tried moving the master database yet, due to the question I have on configuring the registry value, and whether any of the system database files should be separated or kept together.