部署雲端見證容錯移轉叢集Deploy a Cloud Witness for a Failover Cluster

適用於:適用於:Windows Server(以每年次通道)、Windows Server 2016Applies to: Applies to: Windows Server (Semi-Annual Channel), Windows Server 2016

雲端見證是一種全新的 Windows Server 2016 引進容錯移轉叢集仲裁見證。Cloud Witness is a new type of Failover Cluster quorum witness being introduced in Windows Server 2016. 本主題提供雲端見證功能、案例的支援,以及了解如何設定執行 Windows Server 2016 容錯移轉叢集雲端見證指示的概觀。This topic provides an overview of the Cloud Witness feature, the scenarios that it supports, and instructions about how to configure a cloud witness for a Failover Cluster that is running Windows Server 2016.

雲端見證概觀Cloud Witness overview

圖 1 所示多網站延伸容錯移轉叢集仲裁設定與 Windows Server 2016。Figure 1 illustrates a multi-site stretched Failover Cluster quorum configuration with Windows Server 2016. 在此範例中設定(圖 1),有 2 節點 2 資料中心(稱為網站)。In this example configuration (figure 1), there are 2 nodes in 2 datacenters (referred to as Sites). 請注意,就可以跨多個 2 資料中心叢集。Note, it is possible for a cluster to span more than 2 datacenters. 此外,每個 datacenter 可以有超過 2 節點。Also, each datacenter can have more than 2 nodes. 此設定(自動容錯移轉 SLA)中的一般叢集仲裁設定可讓每個節點投票。A typical cluster quorum configuration in this setup (automatic failover SLA) gives each node a vote. 其中一個額外投票給仲裁見證允許執行即使是一個 datacenter 叢集體驗電源中斷。One extra vote is given to the quorum witness to allow cluster to keep running even if either one of the datacenter experiences a power outage. 很簡單的數學-有 5 總投票,您需要 3 投票給叢集讓它執行。The math is simple - there are 5 total votes and you need 3 votes for the cluster to keep it running.

在第三個不同的檔案共用見證網站 2 節點與其他網站File Share Witness in a third separate site with 2 nodes in 2 other sites
圖 1: 仲裁見證使用檔案共用見證Figure 1: Using a File Share Witness as a quorum witness

在停電一個 datacenter 中,叢集其他資料,讓它執行的是,中心提供等機會建議裝載仲裁見證兩個 datacenter 以外的地方。In case of power outage in one datacenter, to give equal opportunity for the cluster in other datacenter to keep it running, it is recommended to host the quorum witness in a location other than the two datacenters. 這通常表示要求第三個不同的 datacenter(網站)主控檔案伺服器備份檔案共用會做為仲裁見證(共用見證檔案)。This typically means requiring a third separate datacenter (site) to host a File Server that is backing the File Share which is used as the quorum witness (File Share Witness).

大部分的組織不需要第三個不同的 datacenter 裝載備份檔案共用見證檔案伺服器。Most organizations do not have a third separate datacenter that will host File Server backing the File Share Witness. 這表示組織主要主機檔案伺服器的兩個資料中心的擴充功能,讓該 datacenter 主要資料中心。This means organizations primarily host the File Server in one of the two datacenters, which by extension, makes that datacenter the primary datacenter. 在案例中為其他 datacenter 將只會有 2 投票低於仲裁大部分的 3 投票所需的其中主要 datacenter 中停電,叢集想當機。In a scenario where there is power outage in the primary datacenter, the cluster would go down as the other datacenter would only have 2 votes which is below the quorum majority of 3 votes needed. 第三個不同的資料中心主控檔案伺服器已針對,對於維護備份檔案共用見證可用性檔案伺服器的費用。For the customers that have third separate datacenter to host the File Server, it is an overhead to maintain the highly available File Server backing the File Share Witness. 主控檔案共用見證執行客體 OS 中有檔案伺服器的虛擬電腦公用雲端是同時設定和維護重要的負擔。Hosting virtual machines in the public cloud that have the File Server for File Share Witness running in Guest OS is a significant overhead in terms of both setup & maintenance.

雲端見證是新的容錯移轉叢集仲裁見證做為(2 圖)仲裁點使用 Microsoft Azure 的類型。Cloud Witness is a new type of Failover Cluster quorum witness that leverages Microsoft Azure as the arbitration point (figure 2). 使用 Azure Blob 儲存空間來讀取/寫入可供您在 split-brain 解析度仲裁點大型物件檔案。It uses Azure Blob Storage to read/write a blob file which is then used as an arbitration point in case of split-brain resolution.

還有重大好處,這種方式:There are significant benefits which this approach:

  1. 使用 Microsoft Azure(不需要的第三個不同的 datacenter)。Leverages Microsoft Azure (no need for third separate datacenter).
  2. 使用標準可用 Azure Blob 儲存(虛擬裝載公開雲端中的電腦不額外維護費用)。Uses standard available Azure Blob Storage (no extra maintenance overhead of virtual machines hosted in public cloud).
  3. Azure 相同的儲存空間帳號可用於多個叢集(每個叢集的一個大型物件檔案; 叢集唯一 id 做為 blob 檔案名稱)。Same Azure Storage Account can be used for multiple clusters (one blob file per cluster; cluster unique id used as blob file name).
  4. 極低持續 $cost 儲存過去(每個大型物件檔案,撰寫大型物件檔案更新一次叢集節點狀態時變更非常小資料)。Very low on-going $cost to the Storage Account (very small data written per blob file, blob file updated only once when cluster nodes' state changes).
  5. 建雲端見證資源類型。Built-in Cloud Witness resource type.

示範多網站延伸的叢集雲端見證仲裁見證為的簡圖
圖 2 所示:多網站延伸雲端見證的叢集為仲裁見證Figure 2: Multi-site stretched clusters with Cloud Witness as a quorum witness

如圖 2 所示,還有所需的任何第三個不同網站。As shown in figure 2, there is no third separate site that is required. 雲端見證,例如其他仲裁見證取得投票和參與仲裁計算。Cloud Witness, like any other quorum witness, gets a vote and can participate in quorum calculations.

雲端見證:單一見證類型支援案例Cloud Witness: Supported scenarios for single witness type

如果您擁有所有節點位置(的擴充功能的 Azure)都連接網際網路容錯移轉叢集部署,,建議您將雲端見證設定為您仲裁見證資源。If you have a Failover Cluster deployment, where all nodes can reach the internet (by extension of Azure), it is recommended that you configure a Cloud Witness as your quorum witness resource.

一些案例的支援使用雲端見證為仲裁見證如下所示:Some of the scenarios that are supported use of Cloud Witness as a quorum witness are as follows:

  • 損壞修復延展多網站叢集(看到圖 2)。Disaster recovery stretched multi-site clusters (see figure 2).
  • 容錯不共用存放區(SQL 永遠上等)。Failover Clusters without shared storage (SQL Always On etc.).
  • Microsoft Azure 一樣角色(或任何其他公用雲端)裝載的客體 OS 中執行容錯。Failover Clusters running inside Guest OS hosted in Microsoft Azure Virtual Machine Role (or any other public cloud).
  • 執行中客體 OS 的虛擬機器裝載私人直上雲霄容錯。Failover Clusters running inside Guest OS of Virtual Machines hosted in private clouds.
  • 儲存空間叢集使用或不共用存放裝置,例如延展檔案伺服器叢集。Storage clusters with or without shared storage, such as Scale-out File Server clusters.
  • 小分公司叢集(即使是節點 2 叢集)Small branch-office clusters (even 2-node clusters)

開始使用 Windows Server 2012 R2,最好是叢集會自動管理見證投票並節點投票給動態仲裁與設定見證。Starting with Windows Server 2012 R2, it is recommended to always configure a witness as the cluster automatically manages the witness vote and the nodes vote with Dynamic Quorum.

用於叢集雲端見證設定 Set up a Cloud Witness for a cluster

為您叢集仲裁見證設定雲端見證,請完成下列步驟:To set up a Cloud Witness as a quorum witness for your cluster, complete the following steps:

  1. 建立儲存空間作為雲端見證 Azure 帳號Create an Azure Storage Account to use as a Cloud Witness
  2. 為您叢集仲裁見證設定雲端見證。Configure the Cloud Witness as a quorum witness for your cluster.

建立儲存空間作為雲端見證 Azure 帳號Create an Azure Storage Account to use as a Cloud Witness

本章節告訴您如何建立儲存空間 account 檢視及複製端點 Url 和存取帳號該按鍵。This section describes how to create a storage account and view and copy endpoint URLs and access keys for that account.

若要設定雲端見證,您必須有效的 Azure 儲存帳號,可以用來儲存(用於仲裁)大型物件檔案。To configure Cloud Witness, you must have a valid Azure Storage Account which can be used to store the blob file (used for arbitration). 雲端見證建立已知容器msft-雲端式見證底下 Microsoft 儲存體 Account。Cloud Witness creates a well-known Container msft-cloud-witness under the Microsoft Storage Account. 雲端見證寫入叢集對應的單一的大型物件檔案的唯一 ID 用在此大型物件檔案的檔名為msft-雲端式見證容器。Cloud Witness writes a single blob file with corresponding cluster's unique ID used as the file name of the blob file under this msft-cloud-witness container. 這表示,您可以使用相同的 Microsoft Azure 儲存 Account 設定多個不同的叢集雲端見證。This means that you can use the same Microsoft Azure Storage Account to configure a Cloud Witness for multiple different clusters.

當您使用雲端見證設定多個不同的相同的儲存空間 Azure 帳號叢集,單一msft-雲端式見證就會自動建立容器。When you use the same Azure Storage Account for configuring Cloud Witness for multiple different clusters, a single msft-cloud-witness container gets created automatically. 此容器包含每個叢集的一位大型物件檔案。This container will contain one-blob file per cluster.

若要建立 Azure 儲存 accountTo create an Azure storage account

  1. 若要登入Azure 入口網站Sign in to the Azure Portal.
  2. 在 [中樞] 功能表中,選取新-> 資料 + 儲存空間]-> [儲存空間 account。On the Hub menu, select New -> Data + Storage -> Storage account.
  3. 在 [建立儲存空間 account 頁面中,執行下列動作:In the Create a storage account page, do the following:

    1. 輸入儲存空間洽詢您的名稱。Enter a name for your storage account.
      儲存空間 account 名稱必須之間 3 到 24 個字元,且可能會包含數字和只有小寫字母。Storage account names must be between 3 and 24 characters in length and may contain numbers and lowercase letters only. 必須唯一 Azure 儲存 account 名稱。The storage account name must also be unique within Azure.

    2. 適用於帳號類型通用For Account kind, select General purpose.
      您不能使用雲端見證 Blob 儲存 account。You can't use a Blob storage account for a Cloud Witness.

    3. 適用於效能標準For Performance, select Standard.
      您不能使用雲端見證 Azure Premium 儲存空間。You can't use Azure Premium Storage for a Cloud Witness.
    4. 適用於複製在本機備援儲存 (LRS)For Replication, select Locally-redundant storage (LRS) .
      容錯做為朗讀資料時,需要一些一致性保證仲裁點,使用大型物件檔案。Failover Clustering uses the blob file as the arbitration point, which requires some consistency guarantees when reading the data. 您必須選取 therefor儲存在本機備援複寫類型。Therefor you must select Locally-redundant storage for Replication type.

檢視及儲存便捷鍵複製 Azure 儲存洽詢您的View and copy storage access keys for your Azure Storage Account

當您建立的 Microsoft Azure 儲存帳號時,它就關聯兩個快速鍵會自動專為主要便捷鍵和次要便捷鍵。When you create a Microsoft Azure Storage Account, it is associated with two Access Keys that are automatically generated - Primary Access key and Secondary Access key. 建立雲端見證第一次,使用主要便捷鍵For a first-time creation of Cloud Witness, use the Primary Access Key. 有是有關使用雲端見證哪一個按鍵無限制。There is no restriction regarding which key to use for Cloud Witness.

若要檢視和複製存放裝置便捷鍵To view and copy storage access keys

Azure 入口網站中瀏覽到儲存帳號,請按一下[所有設定],然後按一下 [以檢視,請複製和產生您 account 便捷鍵。In the Azure Portal, navigate to your storage account, click All settings and then click Access Keys to view, copy, and regenerate your account access keys. 讓便捷鍵也包含預先設定的連接字串使用您的主要和次要金鑰,您可以複製(看到圖 4)將應用程式中使用。The Access Keys blade also includes pre-configured connection strings using your primary and secondary keys that you can copy to use in your applications (see figure 4).

Microsoft Azure 管理便捷鍵對話方塊的開發進程的快照
儲存空間快速鍵圖 4:Figure 4: Storage Access Keys

當您建立儲存空間帳號時,下列 Url 專使用的格式:When you create a Storage Account, the following URLs are generated using the format: https://<Storage Account Name>.<Storage Type>.<Endpoint>

雲端見證一律會使用Blob儲存空間類型。Cloud Witness always uses Blob as the storage type. Azure 使用。core.windows.net的端點。Azure uses .core.windows.net as the Endpoint. 在雲端見證設定時,可能是,您設定的不同的端點根據您的案例(例如 Microsoft Azure 資料中心中國地區都有不同的端點)。When configuring Cloud Witness, it is possible that you configure it with a different endpoint as per your scenario (for example the Microsoft Azure datacenter in China has a different endpoint).

注意

端點 URL 由自動見證雲端資源和設定的任何額外的步驟會所需的 URL。The endpoint URL is generated automatically by Cloud Witness resource and there is no extra step of configuration necessary for the URL.

在 Azure 入口網站瀏覽到儲存帳號,請按一下[所有設定],然後按一下 [屬性以檢視及複製您的端點 Url(看到圖 5)。In the Azure Portal, navigate to your storage account, click All settings and then click Properties to view and copy your endpoint URLs (see figure 5).

雲端見證端點連結的開發進程的快照
圖 5 所示:雲端見證端點 URL 連結Figure 5: Cloud Witness endpoint URL links

如需有關建立及管理 Azure 儲存帳號,請查看有關 Azure 儲存帳號For more information about creating and managing Azure Storage Accounts, see About Azure Storage Accounts

雲端見證設定為仲裁見證叢集Configure Cloud Witness as a quorum witness for your cluster

雲端見證設定為在建置到容錯移轉叢集管理員現有仲裁設定精靈良好整合。Cloud Witness configuration is well-integrated within the existing Quorum Configuration Wizard built into the Failover Cluster Manager.

若要設定雲端見證仲裁見證為To configure Cloud Witness as a Quorum Witness

  1. 上市容錯移轉叢集管理員。Launch Failover Cluster Manager.
  2. 以滑鼠右鍵按一下叢集]-> [更多] 動作 -> 設定叢集仲裁設定(看到圖 6)。Right-click the cluster -> More Actions -> Configure Cluster Quorum Settings (see figure 6). 這時限設定叢集仲裁精靈。This launches the Configure Cluster Quorum wizard.
    <span data-ttu-id="422ac-198">功能表路徑 Configue 叢集仲裁設定容錯移轉叢集管理員 UI 中的開發進程的快照](media/Deploy-a-Cloud-Witness-for-a-Failover-Cluster/CloudWitness_7.png)**圖 6。叢集仲裁設定**</span><span class="sxs-lookup"><span data-stu-id="422ac-198">Snapshot of the menu path to Configue Cluster Quorum Settings in the Failover Cluster Manager UI Figure 6. Cluster Quorum Settings

  3. 選擇仲裁設定頁面上,選取 [選取仲裁見證(請圖 7)。On the Select Quorum Configurations page, select Select the quorum witness (see figure 7).

    快照 '選取 quotrum 見證' 選項叢集仲裁精靈中的按鈕
    圖 7 所示。Figure 7. 選取 [仲裁設定Select the Quorum Configuration

  4. 選擇仲裁見證頁面上,選取 [設定雲端見證(請圖 8)。On the Select Quorum Witness page, select Configure a cloud witness (see figure 8).

    若要選取雲端見證適當的選項按鈕的開發進程的快照
    圖 8。Figure 8. 選取 [仲裁見證Select the Quorum Witness

  5. 設定雲端見證頁面上,輸入下列資訊:On the Configure Cloud Witness page, enter the following information:

    1. (必要的參數)Azure 儲存 Account 名稱。(Required parameter) Azure Storage Account Name.
    2. (必要的參數)儲存空間過去對應便捷鍵。(Required parameter) Access Key corresponding to the Storage Account.
      1. 建立第一次時, 使用主要便捷鍵(檢視圖 5)When creating for the first time, use Primary Access Key (see figure 5)
      2. 旋轉主要便捷鍵時, 使用次要便捷鍵(檢視圖 5)When rotating the Primary Access Key, use Secondary Access Key (see figure 5)
    3. (選擇性參數)如果您想要使用不同的 Azure 服務端點(例如 Microsoft Azure 服務在中國),然後更新端點伺服器名稱。(Optional parameter) If you intend to use a different Azure service endpoint (for example the Microsoft Azure service in China), then update the endpoint server name.

      雲端見證設定窗格叢集仲裁精靈中的開發進程的快照
      圖 9:設定您的雲端見證Figure 9: Configure your Cloud Witness

  6. 在成功雲端見證的設定,您可以檢視新建的見證資源容錯移轉叢集管理員中嵌入式管理單元(看到圖 10)。Upon successful configuration of Cloud Witness, you can view the newly created witness resource in the Failover Cluster Manager snap-in (see figure 10).

    成功的雲端見證的設定
    圖 10:的雲端見證成功的設定Figure 10: Successful configuration of Cloud Witness

設定使用 PowerShell 雲端見證Configuring Cloud Witness using PowerShell

現有的 Set-ClusterQuorum PowerShell 命令已新增額外的參數對應至雲端見證。The existing Set-ClusterQuorum PowerShell command has new additional parameters corresponding to Cloud Witness.

您可以設定雲端見證使用Set-ClusterQuorum下列 PowerShell 命令:You can configure Cloud Witness using the Set-ClusterQuorum following PowerShell command:

Set-ClusterQuorum -CloudWitness -AccountName <StorageAccountName> -AccessKey <StorageAccountAccessKey>

萬一您必須使用不同的端點(少數):In case you need to use a different endpoint (rare):

Set-ClusterQuorum -CloudWitness -AccountName <StorageAccountName> -AccessKey <StorageAccountAccessKey> -Endpoint <servername>  

使用雲端見證 azure 儲存 Account 注意事項Azure Storage Account considerations with Cloud Witness

在雲端見證設定為容錯移轉叢集仲裁見證時,請參考下列:When configuring a Cloud Witness as a quorum witness for your Failover Cluster, consider the following:

  • 儲存便捷鍵,而您容錯移轉叢集會建立,及安全地儲存 [分享存取權安全性 (SAS) 預付碼。Instead of storing the Access Key, your Failover Cluster will generate and securely store a Shared Access Security (SAS) token.
  • 只要便捷鍵有效正確產生的 SAS 預付碼。The generated SAS token is valid as long as the Access Key remains valid. 旋轉時主要便捷鍵,請務必第一次更新之前,請先重新存取主要次要便捷鍵雲端見證(所有您叢集上所使用的儲存空間 Account)。When rotating the Primary Access Key, it is important to first update the Cloud Witness (on all your clusters that are using that Storage Account) with the Secondary Access Key before regenerating the Primary Access Key.
  • 雲端見證使用 Azure 儲存 Account 服務的其他 HTTPS 介面。Cloud Witness uses HTTPS REST interface of the Azure Storage Account service. 這表示它需要開放所有叢集節點 HTTPS 連接埠。This means it requires the HTTPS port to be open on all cluster nodes.

使用雲端見證 proxy 注意事項Proxy considerations with Cloud Witness

雲端見證使用 HTTPS(預設連接埠 443)建立與 Azure blob 服務通訊。Cloud Witness uses HTTPS (default port 443) to establish communication with Azure blob service. 請確認透過網路 Proxy,您可以存取 HTTPS 連接埠。Ensure that HTTPS port is accessible via network Proxy.

也了See Also