0

I would like to change the path for a SQL Server Filestream but I can't find any information on this. I know how to change the mdf and ldf filenames, but can't seem to find how to change the folder name where the FileStream stores the data.

Lieven Cardoen
  • 517
  • 2
  • 8
  • 17

2 Answers2

1
  1. Alter database modify file setting the new path. The file/file group will be set to offline.
  2. Manually copy the Filestream container to the new location specified in (1).
  3. Bring the file/file group back online.

Starting with Sql Server 2008 R2 you can do the operation online by adding a second Filestream container (located in the new folder) to the current file group, then shrink the original container (WITH EMPTY option). Once all data is migrated and garbage collected so that the original container is empty, you can remove it from the Filestream file group.

Pawel Marciniak
  • 205
  • 1
  • 4
0

One solution can be found here.

Lieven Cardoen
  • 517
  • 2
  • 8
  • 17