SharePoint Server 中的 RBS 概觀Overview of RBS in SharePoint Server

摘要:了解如何使用 SharePoint Server 2016 和 SharePoint 2013 伺服器陣列的遠端 BLOB 儲存 (RBS)。Summary: Learn about how to use Remote BLOB Storage (RBS) in a SharePoint Server 2016 and SharePoint 2013 farm.

本文說明 SharePoint Server 如何與遠端 BLOB 儲存 (RBS) 及 SQL Server 搭配使用,以最佳化資料庫儲存資源。This article describes how to use SharePoint Server together with Remote BLOB Storage (RBS) and SQL Server to optimize database storage resources.

在實作 RBS 之前,強烈建議您評估其潛在成本和效益。如需如何在 SharePoint Server 安裝中使用 RBS 的詳細資訊及建議,請參閱<決定在 SharePoint Server 中使用 RBS>。Before you implement RBS, we highly recommend that you evaluate its potential costs and benefits. For more information and recommendations about how to use RBS in a SharePoint Server installation, see Deciding to use RBS in SharePoint Server.

注意

[!附註] 除非另有指定,否則本文中的資訊只針對使用 FILESTREAM 提供者的 RBS。如需其他提供者特定的指導,請連絡提供者製造商。Unless otherwise specified, the information in this article is specific to RBS using the FILESTREAM provider. For guidance specific to another provider, contact the provider manufacturer.

RBS 簡介Introduction to RBS

在 SharePoint Server 中,二進位大型物件 (BLOB) 是儲存在資料庫中的大型資料區塊,因其大小和位置而為人所知,而與結構無關;例如 Office 文件或視訊檔案。根據預設,這些 BLOB 又稱為無結構資料,它們是與相關的中繼資料或結構化資料一起直接儲存在 SharePoint 內容資料庫中。由於這些 BLOB 可能非常大,所以最好是將 BLOB 儲存在內容資料庫外面。 BLOB 是永遠不變的。因此,必須為每個 BLOB 版本儲存新的 BLOB 複本。有鑑於此,當資料庫使用量增加時,其 BLOB 資料的總大小會快速擴展,並快速成長為超過資料庫中儲存之文件中繼資料與其他結構化資料的總大小。 BLOB 資料會耗用大量的空間,且會使用到為了資料庫存取模式最佳化的伺服器資源。因此,將 BLOB 資料移出 SQL Server 資料庫,然後移至商品或內容可定址的儲存裝置將有所助益。若要執行這項操作,您可以使用 RBS。In SharePoint Server, a binary large object (BLOB) is a large block of data stored in a database that is known by its size and location instead of by its structure — for example a Office document or a video file. By default, these BLOBs, also known as unstructured data, are stored directly in the SharePoint content database together with the associated metadata, or structured data. Because these BLOBs can be very large, it might be better to store BLOBs outside the content database. BLOBs are immutable. Therefore, a new copy of the BLOB must be stored for each version of that BLOB. Because of this, as a database's usage increases, the total size of its BLOB data can expand quickly and grow larger than the total size of the document metadata and other structured data that is stored in the database. BLOB data can consume lots of space and uses server resources that are optimized for database access patterns. Therefore, it can be helpful to move BLOB data out of the SQL Server database, and onto commodity or content addressable storage. To do this, you can use RBS.

RBS 是結合為增益集功能套件的 SQL Server 程式庫 API 集,您可以在安裝下列項目時一起安裝:RBS is a SQL Server library API set that is incorporated as an add-in feature pack that you can install when you install the following:

  • SQL Server 2014 Service Pack 1 (SP1)SQL Server 2014 Service Pack 1 (SP1)

  • SQL Server 2014SQL Server 2014

  • SQL Server 2012SQL Server 2012

  • SQL Server 2008 R2 ExpressSQL Server 2008 R2 Express

  • SQL Server 2008 R2SQL Server 2008 R2

  • SQL Server 2008SQL Server 2008

此 RBS 功能可讓應用程式 (例如 SharePoint Server) 將 BLOB 儲存在內容資料庫外面。在外部儲存 BLOB 可降低所需的 SQL Server 資料庫儲存空間。每個 BLOB 的中繼資料是儲存在 SQL Server 資料庫中,而 BLOB 是儲存在 RBS 存放區中。The RBS feature enables applications, such as SharePoint Server, to store BLOBs in a location outside the content databases. Storing the BLOBs externally can reduce how much SQL Server database storage space is required. The metadata for each BLOB is stored in the SQL Server database and the BLOB is stored in the RBS store.

SharePoint Server 使用 RBS 功能,將 BLOB 儲存在內容資料庫的外面。SQL Server 和 SharePoint Server 會基於不同資料庫,共同管理 RBS 外部存放區的資料庫記錄和內容的資料完整性。SharePoint Server uses the RBS feature to store BLOBs outside the content database. SQL Server and SharePoint Server jointly manage the data integrity between the database records and contents of the RBS external store on a per-database basis.

RBS 包含下列元件:RBS is composed of the following components:

  • RBS 用戶端文件庫RBS client library

    RBS 用戶端文件庫包含受管理文件庫,以協調 BLOB 儲存與 SharePoint Server、SQL Server 和 RBS 提供者元件。An RBS client library consists of a managed library that coordinates the BLOB storage with SharePoint Server, SQL Server, and RBS provider components.

  • 遠端 BLOB 儲存提供者Remote BLOB Storage provider

    RBS 提供者包含受管理文件庫,以及選擇性地與 BLOB 存放區進行通訊的一組原生文件庫。An RBS provider consists of a managed library and, optionally, a set of native libraries that communicate with the BLOB store.

    RBS 提供者的一個範例是 SQL FILESTREAM 提供者。SQL FILESTREAM 提供者是 SQL Server 2014 Service Pack 1 (SP1) 的增益集功能,可讓您使用 SQL Server 2014 (SP1) 和 NTFS 檔案系統的結合來儲存和有效率地存取 BLOB 資料。如需有關 FILESTREAM 的詳細資訊,請參閱<FILESTREAM (SQL Server)>如需有關如何啟用和設定 FILESTREAM 的詳細資訊,請參閱<啟用和設定 FILESTREAM>。An example of an RBS provider is the SQL FILESTREAM provider. The SQL FILESTREAM provider is an add-in feature of SQL Server 2014 Service Pack 1 (SP1) that enables storage of and efficient access to BLOB data by using a combination of SQL Server 2014 (SP1) and the NTFS file system. For more information about FILESTREAM, see FILESTREAM (SQL Server) For information about how to enable and configure FILESTREAM, see Enable and Configure FILESTREAM.

  • BLOB 存放區BLOB store

    BLOB 存放區是用來儲存 BLOB 資料的實體。這可以是內容定址儲存 (CAS) 解決方案、支援伺服器訊息區 (SMB) 的檔案伺服器或 SQL Server 資料庫。A BLOB store is an entity that is used to store BLOB data. This can be a content-addressable storage (CAS) solution, a file server that supports Server Message Block (SMB), or a SQL Server database.

RBS 提供者RBS providers

RBS 使用「提供者」連線至使用 RBS API 的任何專屬 BLOB 存放區。透過此類提供者使用 RBS API,SharePoint Server 支援可存取 BLOB 資料的 BLOB 儲存實作。有兩種類型的 RBS 提供者,分別是本機和遠端。RBS uses a provider to connect to any dedicated BLOB store that uses the RBS APIs. SharePoint Server supports a BLOB storage implementation that accesses BLOB data by using the RBS APIs through such a provider. There are two kinds of RBS providers, local and remote.

RBS 提供者儲存 BLOB 資料的位置取決於您使用的提供者。若為 FILESTREAM 提供者,則資料不會儲存在 .mdf 檔案中,而是儲存在與資料庫相關聯的另一個資料夾中。The location in which an RBS provider stores the BLOB data depends on the provider that you use. In the case of the FILESTREAM provider, the data is not stored in the .mdf file. Instead, it is stored in another folder that is associated with the database.

本機 RBS 提供者Local RBS provider

本機提供者會將 BLOB 儲存到資料庫外面,但在執行 SQL Server 的同一部伺服器上。透過本機 RBS FILESTREAM 提供者將解壓縮的 BLOB 資料放置在不同 (即較少消耗資源) 的本機磁碟上,以節省資源。BLOB 是與中繼資料儲存在相同的 Filegroup 中,因此可使用 SharePoint Server 的功能,例如 管理中心的備份與還原。A local provider stores the BLOBS outside the database but on the same server that is running SQL Server. You can conserve resources by using the local RBS FILESTREAM provider to put the extracted BLOB data on a different (that is, less resource-intensive) local disk. Because the BLOBs are stored in the same Filegroup as the metadata, SharePoint Server features, such as backup and restore in Central Administration, can be used.

RBS FILESTREAM 提供者會在您安裝 SQL Server 2014 Service Pack 1 (SP1) 時作為增益集提供。RBS FILESTREAM 提供者使用 SQL Server FILESTREAM 功能將 BLOB 儲存至附加到相同資料庫並儲存在本機伺服器上的其他資源中。FILESTREAM 功能可使用基礎 NTFS 檔案系統管理 SQL 資料庫中的 BLOB。The RBS FILESTREAM provider is available as an add-in when you install SQL Server 2014 Service Pack 1 (SP1). The RBS FILESTREAM provider uses the SQL Server FILESTREAM feature to store BLOBs in an additional resource that is attached to the same database and stored locally on the server. The FILESTREAM feature manages BLOBs in a SQL database by using the underlying NTFS file system.

重要

僅支援在本機硬碟上或連接的 Small Computer System Interface (iSCSI) 裝置上使用本機 FILESTREAM 提供者。您無法在遠端儲存裝置 (例如網路連接儲存裝置 (NAS)) 上使用本機 RBS FILESTREAM 提供者。The local FILESTREAM provider is supported only when it is used on local hard disk drives or an attached Internet Small Computer System Interface (iSCSI) device. You cannot use the local RBS FILESTREAM provider on remote storage devices such as network attached storage (NAS).

遠端 RBS 提供者Remote RBS provider

遠端 RBS 提供者會將 BLOB 儲存在個別的伺服器上。通常是與資料庫伺服器位於相同網路的個別磁碟區上。A remote RBS provider stores the BLOBs on a separate server. This is typically on a separate volume on the same network as the database server.

BLOB 不是與中繼資料儲存在相同的 Filegroup 中,因此部分 SharePoint Server 功能 (例如,管理中心的備份與還原) 無法與遠端 RBS 提供者搭配使用。中繼資料和 BLOB 必須分開管理。如需可與提供者搭配使用之功能的詳細資訊,請連絡提供者製造商。Because the BLOBs are not stored in the same Filegroup with the metadata, some SharePoint Server features — for example, backup and restore in Central Administration — cannot be used with remote RBS providers. The metadata and the BLOBs must be managed separately. For more information about what features can be used with the provider, contact the provider manufacturer.

RBS 與 SharePoint Server 搭配使用Using RBS together with SharePoint Server

SharePoint Server 2016 支援包含在 SQL Server 2014 (SP1) 中的 FILESTREAM 提供者。這一版的 RBS 包含在 SQL Server 安裝媒體上,但不是透過 SQL Server 安裝程式安裝。SharePoint Server 2016 supports the FILESTREAM provider that is included in SQL Server 2014 (SP1). This version of RBS is included on the SQL Server installation media, but is not installed by the SQL Server Setup program..

SharePoint 2013 支援包含在 SQL Server 2008 R2 Feature Pack 中的 SQL Server 遠端 BLOB 存放區安裝套件、SQL Server 2012 和 SQL Server 2014 中的 FILESTREAM 提供者。這些版本的 RBS 位於下列位置:SharePoint 2013 supports the FILESTREAM provider that is included in the SQL Server Remote BLOB Store installation package from the Feature Pack for SQL Server 2008 R2, SQL Server 2012, and SQL Server 2014. These versions of RBS are available at the following locations:

請注意,SQL Server 2014 的 SQL Server 遠端 BLOB 存放區安裝套件是 SharePoint Server 2016 支援的唯一 RBS 版本。SharePoint 2013 只支援 SQL Server 2008 R2 Feature Pack 中的 SQL Server 遠端 BLOB 存放區安裝套件 和更新版本的 RBS。舊版將不予以支援。第三方 RBS 提供者也可與 RBS API 一起使用,以建立與 SharePoint Server 相容的 BLOB 儲存解決方案。Be aware that SQL Server Remote BLOB Store installation package for SQL Server 2014 is the only version of RBS that is supported by SharePoint Server 2016. SQL Server Remote BLOB Store installation package from the Feature Pack for SQL Server 2008 R2 and later are the only versions of RBS that are supported by SharePoint 2013. Earlier versions are not supported. Third-party RBS providers can also be used with the RBS APIs to create a BLOB storage solution that is compatible with SharePoint Server.

在 SharePoint Server 中,無論使用哪個 RBS 提供者,網站集合備份與還原以及網站匯入或匯出將會下載檔案內容,並將其上傳回伺服器。此程序稱為「深層複製」。不過,FILESTREAM 提供者是 SharePoint Server伺服器陣列資料庫備份與還原作業目前所支援的唯一提供者。In SharePoint Server, site collection backup and restore and site import or export will download the file contents and upload them back to the server regardless of which RBS provider is being used. This process is known as a deep copy. However, the FILESTREAM provider is the only provider that is currently supported for SharePoint Server farm database backup and restore operations.

若要使用 RBS,您必須在 SharePoint Server 安裝的每部伺服器上以及拓撲中的每個資料庫伺服器上安裝 RBS 提供者。此提供者包含一組 DLL,可實作 RBS API 方法以及執行實際的外部 BLOB 作業。To use RBS, you must install an RBS provider on each server where SharePoint Server is installed and on each database server in the topology. The provider includes a set of DLLs that implement methods for the RBS APIs and perform the actual operation of externalizing the BLOBs.

注意

[!附註] 如果在 SharePoint Server 應用程式伺服器上執行的 Visio Web 服務尚未安裝 RBS 提供者,當您嘗試從這個伺服器開啟 Visio 圖表時,會出現 Visio 錯誤。如果您想要開啟該伺服器上的 Visio 圖表,必須在執行 Visio Graphics Service 的 SharePoint Server 伺服器上安裝 RBS 用戶端。If Visio web services runs on SharePoint Server application servers that do not have an RBS provider installed, a Visio error occurs when you attempt to open a Visio diagram from this server. You must install an RBS client on SharePoint Server servers that run the Visio Graphics Service if you want to open Visio diagrams on that server.

SharePoint Server 2016:若要在遠端伺服器上執行 RBS,您必須在執行 SQL Server 的伺服器 (中繼資料儲存於此處的資料庫中) 上執行 SQL Server 2014 (SP1) Enterprise。SharePoint Server 2016: To run RBS on a remote server, you must be running SQL Server 2014 (SP1) Enterprise on the server that is running SQL Server where the metadata is stored in the database.

若您計劃將 BLOB 資料儲存在與 SharePoint Server 2016 內容資料庫不同的 RBS 儲存中,則必須執行 SQL Server 2014 (SP1)。此原則適用於所有 RBS 提供者。If you plan to store BLOB data in an RBS store that differs from your SharePoint Server 2016 content databases, you must run SQL Server 2014 (SP1). This is true for all RBS providers.

SharePoint Server 2013:若要在遠端伺服器上執行 RBS,您必須在執行 SQL Server 的伺服器 (中繼資料儲存於此處的資料庫中) 上執行 SQL Server 2008 R2、SQL Server 2012 或 SQL Server 2014 Enterprise。SharePoint Server 2013: To run RBS on a remote server, you must be running SQL Server 2008 R2, SQL Server 2012, or SQL Server 2014 Enterprise on the server that is running SQL Server where the metadata is stored in the database.

若您計劃將 BLOB 資料儲存在與 SharePoint 2013 內容資料庫不同的 RBS 存放區中,則必須執行 SQL Server 2008 SP1 與累計更新 2、SQL Server 2012 或 SQL Server 2014。此原則適用於所有 RBS 提供者。If you plan to store BLOB data in an RBS store that differs from your SharePoint 2013 content databases, you must run SQL Server 2008 with SP1 and Cumulative Update 2, SQL Server 2012, or SQL Server 2014. This is true for all RBS providers.

建議 FILESTREAM 提供者將內容資料庫超過 4 GB 之 Windows SharePoint Services 3.0 的獨立安裝升級為 SharePoint 2013,建立本機中資料與現有的內容資料庫的關聯,且不需要 SQL Server Enterprise。The FILESTREAM provider that is recommended for upgrading from stand-alone installations of Windows SharePoint Services 3.0 that have content databases that are over 4 gigabytes (GB) to SharePoint 2013 associates data locally with the current content database, and does not require SQL Server Enterprise.

重要

[!重要事項] 雖然 RBS 可用來將 BLOB 資料儲存到外部,使用的工具或產品若不是 SharePoint Server,則無法支援存取或變更這些 BLOB。必須使用 SharePoint Server 才能進行所有存取。Although RBS can be used to store BLOB data externally, accessing or changing those BLOBs is not supported using any tool or product other than SharePoint Server. All access must occur by using SharePoint Server only.

另請參閱See also

其他資源Other Resources

二進位大型物件 (Blob) 資料 (SQL Server)Binary Large Object (Blob) Data (SQL Server)

FILESTREAM (SQL Server)FILESTREAM (SQL Server)

遠端 BLOB 存放區提供者的程式庫實作規格Remote BLOB Store Provider Library Implementation Specification

以 SharePoint 2013 和 SQL Server 2012 安裝及設定 RBSInstall and configure RBS with SharePoint 2013 and SQL Server 2012