How to move FileStream enable DB from one Server to another

hpradhan08
hpradhan08 used Ask the Experts™
on

Hi there,
I'm trying to move the FileStream enabled DB from one server to another and got the following error:

Msg 3156, Level 16, State 6, Line 1
File 'FS_FILESTREAM' cannot be restored to 'E:\Microsoft SQL Server\MSSQL10.TESTDB4\Data\FS_FILESTREAM'. 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.

Could you please help?

Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®

Author

Commented:
I saw those articles and didn't help me. That's because I'm restoring from primary to secondary server... Could you please help?

Getting following error:

Msg 3156, Level 16, State 6, Line 1
File 'FS_FILESTREAM' cannot be restored to 'E:\Microsoft SQL Server\MSSQL10.TESTDB4\Data\FS_FILESTREAM'. 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.

Here are the scripts:

USE [master]
GO
RESTORE DATABASE ReportGenerator
FROM DISK = N'F:\Temp\ReportGenerator.bak'
WITH
MOVE 'ReportGenerator_Data_01' TO 'E:\Microsoft SQL Server\MSSQL10.TESTDB4\Data\ReportGenerator_Data_01.MDF',                                                                                                                                                                                                    
MOVE 'ReportGenerator_log' TO 'E:\Microsoft SQL Server\MSSQL10.TESTDB4\TLogs\ReportGenerator_log.LDF',
MOVE 'ReportGenerator_Data_02' TO 'E:\Microsoft SQL Server\MSSQL10.TESTDB4\Data\ReportGenerator_Data_02.NDF',
MOVE 'ReportGenerator_Data_03' TO 'E:\Microsoft SQL Server\MSSQL10.TESTDB4\Data\ReportGenerator_Data_03.NDF',
MOVE 'ReportGenerator_Data_04' TO 'E:\Microsoft SQL Server\MSSQL10.TESTDB4\Data\ReportGenerator_Data_04.NDF',
MOVE 'ReportGenerator_Index_01' TO 'E:\Microsoft SQL Server\MSSQL10.TESTDB4\Data\ReportGenerator_Index_01.NDF',
MOVE 'ReportGenerator_Index_02' TO 'E:\Microsoft SQL Server\MSSQL10.TESTDB4\Data\ReportGenerator_Index_02.NDF',
MOVE 'ReportGenerator_Index_03' TO 'E:\Microsoft SQL Server\MSSQL10.TESTDB4\Data\ReportGenerator_Index_03.NDF',
MOVE 'ReportGenerator_Index_04' TO 'E:\Microsoft SQL Server\MSSQL10.TESTDB4\Data\ReportGenerator_Index_04.NDF',
MOVE 'FS_FileStream_Files_01' TO 'E:\Microsoft SQL Server\MSSQL10.TESTDB4\Data\FS_FileStream_Files_01.NDF',
MOVE 'FS_FILESTREAM' TO 'E:\Microsoft SQL Server\MSSQL10.TESTDB4\Data\FS_FILESTREAM'

what am I doing wrong here?
Learn Ruby Fundamentals

This course will introduce you to Ruby, as well as teach you about classes, methods, variables, data structures, loops, enumerable methods, and finishing touches.

Author

Commented:
Hi there,
Any suggestions please?

Commented:
Copied the filestream before  the restore?
check the drive i which you are about to restore the  backup set
'E:\Microsoft SQL Server\MSSQL10.TESTDB4\Data\FS_FILES is the Path of the primary machine, check whether this path exist on your new server,where you are trying to restore it

Commented:
Not only  'E:\Microsoft SQL Server\MSSQL10.TESTDB4\Data\FS_FILESTREAM' must exists, it must contain the content copied from the original location.

Author

Commented:
Thank you.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial