We have a UAT db (standalone named instance) with filestream enabled, we would like to move the UAT db to production environment (Failover cluster instance). We tried backup-restore, but have difficulties on Filestream data restoration with following errors. You help is highly appreciated.
Msg 3156, Level 16, State 6, Line 1File 'ABCFS' cannot be restored to 'X:\MSSQL10_50.SQLCPORTAL101\MSSQL\FS'. Use WITH MOVE to identify a valid location for the file.
Msg 3119, Level 16, State 1, Line 1
Problems were identified while planning for the RESTORE statement. Previous messages provide details.
Msg 3013, Level 16, State 1, Line 1
RESTORE DATABASE is terminating abnormally.
Below is the script running for DB restore, part 1 script is ok but part 2 is not.
-- Restore the primary filegroup firstrestore database ABC filegroup = 'PRIMARY'
FROM DISK = N'Y:\MSSQL10_50.SQLCPORTAL101\MSSQL\Backup\SQLCPORTAL101$SQLCPORTAL101\ABC\ABC_full.BAK'
WITH Replace, Recovery, file=1
,MOVE N'ABC_UAT' TO N'X:\MSSQL10_50.SQLCPORTAL101\MSSQL\DATA\ABC_data.mdf'
,Move N'ABC_UAT_log' to N'V:\MSSQL10_50.SQLCPORTAL101\MSSQL\Data\ABC_log.ldf'
-- Restore the filestream filegroup and move it to the new location
restore database ABC filegroup = 'ABCFS'
FROM DISK = N'Y:\MSSQL10_50.SQLCPORTAL101\MSSQL\Backup\SQLCPORTAL101$SQLCPORTAL101\ABC\ABC_full.BAK'
WITH MOVE N'ABCFS' TO N'X:\MSSQL10_50.SQLCPORTAL101\MSSQL\FS', REPLACE