Solved

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

Posted on 2010-11-16
6
1,244 Views
Last Modified: 2013-11-05
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?
0
Comment
Question by:Dangeriz
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 2
6 Comments
 
LVL 16

Expert Comment

by:EvilPostIt
ID: 34153186
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.
0
 
LVL 4

Author Comment

by:Dangeriz
ID: 34153419
Thanks for the response.
How do I set the database to emergency mode?
0
 
LVL 16

Expert Comment

by:EvilPostIt
ID: 34153494
ALTER DATABASE DBNAME SET EMERGENCY
GO
DBCC CHECKDB (DBNAME) WITH NO_INFOMSGS
GO

This should show you some errors.
0
Office 365 Training for IT Pros

Learn how to provision tenants, synchronize on-premise Active Directory, implement Single Sign-On, customize Office deployment, and protect your organization with eDiscovery and DLP policies.  Only from Platform Scholar.

 
LVL 4

Accepted Solution

by:
Dangeriz earned 0 total points
ID: 34213467
Hey, all those things I tried (emergency mode, dbcc etc.) didn't work. Thanks for the suggestions though...

I eventually managed to recover the database using the following procedure:

1.      Set the database’s status to “Offline”.
2.      Detach the database.
3.      Move the MDF and LDF to another location.
4.      Create a new database with the exact same name.
5.      Stop the SQL Server Service.
6.      Delete/move the new database’s MDF and LDF files.
7.      Copy the original database’s MDF and LDF back to the default location.
8.      Start the SQL Server Service.

The database status return back to “ONLINE” and all the data and operations are accessible.

This got my database back to a status where I could get all the data back. I wouldn't suggest using this if you have data already in the blob store else you would have lost it all (would have lost it by deleting the folder already).
0
 
LVL 4

Author Comment

by:Dangeriz
ID: 34213476
Author comment.
0
 
LVL 4

Author Closing Comment

by:Dangeriz
ID: 34237225
I eventually found the solution.
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
When using a search centre, I'm going to show you how to configure Sharepoint's search to only return results from the current site collection. Very useful when using Office 365 with multiple site collections.
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
Viewers will learn how the fundamental information of how to create a table.

691 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question