Link to home
Create AccountLog in
Avatar of Dangeriz
DangerizFlag for Taiwan, Province of China

asked on

SharePoint 2010 Remote Blob Store (RBS) - Deleted Blobstore!

Hi All,

I'm trying to implement RBS on my SharePoint 2010 content database. And I have followed the instructions from:
http://www.toddklindt.com/blog/Lists/Posts/Post.aspx?ID=174
and
http://technet.microsoft.com/en-us/library/ee748631.aspx

I configured the databases to use RBS using these SQL statements:

use [WSS_Content]
if not exists (select * from sys.symmetric_keys where name = N'##MS_DatabaseMasterKey##')create master key encryption by password = N'Admin Key Password !2#4'

use [WSS_Content]
if not exists (select groupname from sysfilegroups where groupname=N'RBSFilestreamProvider')alter database [WSS_Content] add filegroup RBSFilestreamProvider contains filestream

use [WSS_Content]
alter database [WSS_Content] add file (name = RBSFilestreamFile, filename = 'D:\Blobstore') to filegroup RBSFilestreamProvider

Immediately, a new folder was created on D: called Blobstore.

I continued with the steps, but failed to get RBS installed at the end. Therefore I tried to delete the blobstore. I first tried to delete the folder D:\Blobstore, but access was denied (i assumed SQL was using it). So then I stopped SQL Server, then shift-deleted the folder D:\Blobstore. After starting up SQL Server again, my content database is inoperable now.

I'm guessing it's a corrupted database now since it can't connect to the D:\Blobstore file. I can't do any actions on this database (I can't detach, backup or anything). I can't expand the database in Management Studio to see it's tables etc, and I can't run any queries against it!

How can I recover this database now?
Avatar of EvilPostIt
EvilPostIt
Flag of United Kingdom of Great Britain and Northern Ireland image

You may be able to set the database to emergency mode and do a DBCC CHECKDB.

If this works and returns errors then after this run....
DBCC CHECK ([DBNAME],REPAIR_ALLOW_DATA_LOSS) 

Open in new window


Although this could result in you losing more data. The other option would be to restore from a backup.
Avatar of Dangeriz

ASKER

Thanks for the response.
How do I set the database to emergency mode?
ALTER DATABASE DBNAME SET EMERGENCY
GO
DBCC CHECKDB (DBNAME) WITH NO_INFOMSGS
GO

This should show you some errors.
ASKER CERTIFIED SOLUTION
Avatar of Dangeriz
Dangeriz
Flag of Taiwan, Province of China image

Link to home
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
See answer
Author comment.
I eventually found the solution.