Following on from my previous post about list scaling and performance. The following posts details configuration of Remote Blob Storage for SharePoint 2010 and SQL Server 2008 R2.
First download the RBS provider for SQL Server 2008 (don’t install it yet):
http://go.microsoft.com/fwlink/?LinkId=177388
Configure file stream for the SQL Server Service using the Configuration Manager:
Execute the following SQL queries:
EXEC sp_configure filestream_access_level, 2
RECONFIGURE
Execute the following SQL to set up a master encryption key and blob store file group:
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' if not exists (select groupname from sysfilegroups where
groupname=N'RBSFilestreamProvider')alter database WSS_Content add filegroup RBSFilestreamProvider contains filestream alter database [WSS_Content] add file (name = RBSFilestreamFile, filename = 'c:\Blobstore')
to filegroup RBSFilestreamProvider
Install the RBS provider with the following command (change DBINSTANCE to your SQL server instance):
msiexec /qn /lvx* rbs_install_log.txt /i RBS_X64.msi TRUSTSERVERCERTIFICATE=true FILEGROUP=PRIMARY DBNAME="WSS_Content" DBINSTANCE="SP2010" FILESTREAMFILEGROUP=RBSFilestreamProvider FILESTREAMSTORENAME=FilestreamProvider_1
If installing RBD on production servers, be sure to run on all WFE’s with the following command (again, change the DBINSTANCE):
msiexec /qn /lvx* rbs_install_log.txt /i RBS_X64.msi DBNAME="WSS_Content" DBINSTANCE="SP2010" ADDLOCAL=”Client,Docs,Maintainer,ServerScript,FilestreamClient,FilestreamServer”
Run the following Power Shell script from the SP2010 Management Console:
$cdb = Get-SPContentDatabase –WebApplication http://sp2010
$rbss = $cdb.RemoteBlobStorageSettings
$rbss.Installed()
$rbss.Enable()
$rbss.SetActiveProviderName($rbss.GetProviderNames()[0])
$rbss
Now create a document library in SharePoint and upload an image to it. Next visit the c:\blobstore directory and look for the GUID sub folder with recent date. Keep drilling down until you find a file. You should see a file with GUID name. Drop this into IE and you should see that it is the same file you uploaded to your document library.
Hey there:
I am having issues with RBS.
Everything described above worked perfectly, in that the RBS log file reports a successful installation and the additional tables were added to the content database in SQL Server.
However, the PowerShell script only seemingly works. I have narrowed it down to the following call:
$rbss.GetProviderNames()
This call returns nothing, which I assume means that the RBS Filestream Provider was not correctly configured.
Scanning the RBS log, I can’t find any reported errors or failures anywhere. Do you think you might know how/when/why the array driving the GetProviderNames() method is populated?
MSDN has the entire SPRemoteBlobStorageSettings object marked as “Internal Use Only.” so no help can be found there.
Any information you can provide would be greatly appreciated.
Thanks!
DMM
Nevermind!
The issue had to do with an entry in the mssqlrbs_resources.rbs_internal_blob_stores table not being created for some very strange reason. Oddly enough, the log file did not report anything related to this omission.
I was able to get it working by uninstalling RBS, removing the RBS Provider File group from SQL, deleting the mssqlrbs tables, and rebuilding the RBSFilestreamProvider in the PRIMARY filegroup.
I then reinstalled RBS and all is well.
Cheers!
DMM