進階選項],然後執行設定檔的更新叢集更新Cluster-Aware Updating advanced options and updating run profiles

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

本主題描述更新執行選項,您可以設定為更新叢集(CAU) 更新會執行。This topic describes Updating Run options that can be configured for a Cluster-Aware Updating (CAU) Updating Run. 當您使用 CAU UI 或 CAU Windows PowerShell cmdlet 適用的更新,或是設定自動更新的選項,就可以設定這些 [進階的選項]。These advanced options can be configured when you use either the CAU UI or the CAU Windows PowerShell cmdlets to apply updates or to configure self-updating options.

大部分的設定可以儲存 XML 檔案稱為更新執行設定檔,並針對較新的更新執行其他。Most configuration settings can be saved as an XML file called an Updating Run Profile and reused for later Updating Runs. 也可以叢集您的環境中使用所提供的 CAU 更新執行選項的預設值。The default values for the Updating Run options that are provided by CAU can also be used in many cluster environments.

對更新執行設定檔及其他選項,您可以指定每個更新執行的相關資訊,請查看下列本主題稍後的區段:For information about additional options that you can specify for each Updating Run and about Updating Run Profiles, see the following sections later in this topic:

指定當您要求更新執行使用更新執行設定檔的選項,可以設定更新執行設定檔的選項Options that you specify when you request an Updating Run Use Updating Run Profiles Options that can be set in an Updating Run Profile

下表列出您可以設定 CAU 更新執行設定檔的選項。The following table lists options that you can set in a CAU Updating Run Profile.

注意

若要設定 PreUpdateScript 或 PostUpdateScript 選項,請確定已安裝 Windows PowerShell 和.NET Framework 4.6 或 4.5 且遠端 PowerShell 可以在每個節點叢集中。To set the PreUpdateScript or PostUpdateScript option, ensure that Windows PowerShell and .NET Framework 4.6 or 4.5 are installed and that PowerShell remoting is enabled on each node in the cluster. 如需詳細資訊,請查看設定中的遠端管理節點需求與最佳做法叢集更新For more information, see Configure the nodes for remote management in Requirements and Best Practices for Cluster-Aware Updating.

選項Option 預設值。Default value 詳細資料Details
StopAfterStopAfter 無限制的時間Unlimited time 之後,更新執行將會停止如果尚未完成的分鐘的時間。Time in minutes after which the Updating Run will be stopped if it has not completed. 注意:的執行指令碼,並執行更新整個程序如果指定更新前或更新後 PowerShell 指令碼,必須先完成在StopAfter的時間限制。Note: If you specify a pre-update or a post-update PowerShell script, the entire process of running scripts and performing updates must be complete within the StopAfter time limit.
WarnAfterWarnAfter 根據預設,不出現任何警告By default, no warning appears 之後,如果尚未完成更新執行(包括更新前指令碼及更新後指令碼,如果設定),會顯示警告分鐘的時間。Time in minutes after which a warning will appear if the Updating Run (including a pre-update script and a post-update script, if they are configured) has not completed.
MaxRetriesPerNodeMaxRetriesPerNode 33 最大的次數(包括更新前指令碼及更新後指令碼,如果設定)更新程序將會重試每個節點。Maximum number of times that the update process (including a pre-update script and a post-update script, if they are configured) will be retried per node. 最大值是 64。The maximum is 64.
MaxFailedNodesMaxFailedNodes 針對大部分叢集,大約一位第三個叢集節點數目的整數For most clusters, an integer that is approximately one-third of the number of cluster nodes 在哪一個更新可能會失敗,可能是因為節點失敗或執行叢集服務停止節點的上限。Maximum number of nodes on which updating can fail, either because the nodes fail or the Cluster service stops running. 如果有一個更多節點失敗,就會停止更新執行。If one more node fails, the Updating Run is stopped.

值的有效範圍是 0 到 1 小於叢集節點數目。The valid range of values is 0 to 1 less than the number of cluster nodes.
RequireAllNodesOnlineRequireAllNodesOnline None 指定所有節點都必須 online,並開始更新之前,您可取得。Specifies that all nodes must be online and reachable before updating begins.
RebootTimeoutMinutesRebootTimeoutMinutes 1515 重新節點(如果重新開機必要)和開始自動 [開始] 畫面的所有服務允許 CAU 分鐘的時間。Time in minutes that CAU will allow for restarting a node (if a restart is necessary) and starting all auto-start services. 如果在重新開機程序未完成在這次,更新執行該節點標示為失敗。If the restart process doesn't complete within this time, the Updating Run on that node is marked as failed.
PreUpdateScriptPreUpdateScript None PowerShell 指令碼執行每個節點上開始更新之前,和之前節點置於維護模式路徑和檔案名稱。The path and file name for a PowerShell script to run on each node before updating begins, and before the node is put into maintenance mode. 必須副檔名.ps1,,路徑加上檔案名稱的總長度不可超過 260 個字元。The file name extension must be .ps1, and the total length of the path plus file name must not exceed 260 characters. 做為最佳做法,指令碼應該位於叢集存放裝置,或,以確保都可以存取所有叢集節點高度可用的網路檔案共用磁碟上。As a best practice, the script should be located on a disk in cluster storage, or at a highly available network file share, to ensure that it is always accessible to all of the cluster nodes. 如果指令碼位於檔案共用網路,請確認您設定朗讀您請求權限的檔案共用群組,每個人,然後限制以防止未經授權的使用者的檔案所竄改寫入權限。If the script is located on a network file share, ensure that you configure the file share for Read permission for the Everyone group, and restrict write access to prevent tampering with the files by unauthorized users.

如果指定更新前指令碼,請確定您的設定,例如與的時間限制 (例如,StopAfter) 允許指令碼已成功執行設定。If you specify a pre-update script, be sure that settings such as the time limits (for example, StopAfter) are configured to allow the script to run successfully. 這些限制跨越執行指令碼,並安裝更新,而不只安裝更新的處理程序整個程序。These limits span the entire process of running scripts and installing updates, not just the process of installing updates.
PostUpdateScriptPostUpdateScript None PowerShell 指令碼執行(之後節點離開維護模式)更新完成之後路徑和檔案名稱。The path and file name for a PowerShell script to run after updating completes (after the node leaves maintenance mode). 必須副檔名.ps1,路徑加上檔案名稱的總長度不可超過 260 個字元。The file name extension must be .ps1 and the total length of the path plus file name must not exceed 260 characters. 做為最佳做法,指令碼應該位於叢集存放裝置,或,以確保都可以存取所有叢集節點高度可用的網路檔案共用磁碟上。As a best practice, the script should be located on a disk in cluster storage, or at a highly available network file share, to ensure that it is always accessible to all of the cluster nodes. 如果指令碼位於檔案共用網路,請確認您設定朗讀您請求權限的檔案共用群組,每個人,然後限制以防止未經授權的使用者的檔案所竄改寫入權限。If the script is located on a network file share, ensure that you configure the file share for Read permission for the Everyone group, and restrict write access to prevent tampering with the files by unauthorized users.

如果指定更新後指令碼,請確定您的設定,例如與的時間限制 (例如,StopAfter) 允許指令碼已成功執行設定。If you specify a post-update script, be sure that settings such as the time limits (for example, StopAfter) are configured to allow the script to run successfully. 這些限制跨越執行指令碼,並安裝更新,而不只安裝更新的處理程序整個程序。These limits span the entire process of running scripts and installing updates, not just the process of installing updates.
ConfigurationNameConfigurationName 這個設定只效果如果您執行指令碼。This setting only has an effect if you run scripts.

若您指定前更新或更新後指令碼,但是您不指定ConfigurationName,使用 PowerShell (Microsoft.PowerShell) 設定預設工作階段。If you specify a pre-update script or a post-update script, but you do not specify a ConfigurationName, the default session configuration for PowerShell (Microsoft.PowerShell) is used.
指定 PowerShell 工作階段組態定義工作階段中的指令碼 (指定的PreUpdateScriptPostUpdateScript) 執行,並可以限制的可執行的命令。Specifies the PowerShell session configuration that defines the session in which scripts (specified by PreUpdateScript and PostUpdateScript) are run, and can limit the commands that can be run.
CauPluginNameCauPluginName Microsoft.WindowsUpdatePluginMicrosoft.WindowsUpdatePlugin 外掛程式您設定的使用預覽更新或執行更新執行叢集更新。Plug-in that you configure Cluster-Aware Updating to use to preview updates or perform an Updating Run. 如需詳細資訊,請查看運作方式叢集更新插For more information, see How Cluster-Aware Updating plug-ins work.
CauPluginArgumentsCauPluginArguments None 一組名稱 = 值以插件,以使用,例如更新配對(引數):A set of name=value pairs (arguments) for the updating plug-in to use, for example:

Domain=Domain.localDomain=Domain.local

這些名稱 = 值配對必須意義外掛程式您在指定的CauPluginNameThese name=value pairs must be meaningful to the plug-in that you specify in CauPluginName.

若要指定引數使用 CAU UI,輸入名稱,長按 Tab 鍵,然後輸入適當的對應To specify an argument using the CAU UI, type the name, press the Tab key, and then type the corresponding value. 按下 Tab 鍵,再試一次,以提供的下一步引數。Press the Tab key again to provide the next argument. 每個名稱會自動以等號(=)。Each name and value are automatically separated with an equal (=) sign. 多個配對會自動以分號。Multiple pairs are automatically separated with semicolons.

預設值的Microsoft.WindowsUpdatePlugin會需要外掛程式,不引數。For the default Microsoft.WindowsUpdatePlugin plug-in, no arguments are needed. 不過,您可以指定選擇性引數,例如指定標準 Windows Update 代理程式查詢字串篩選更新外掛程式套用的設定。However, you can specify an optional argument, for example to specify a standard Windows Update Agent query string to filter the set of updates that are applied by the plug-in. 適用於名稱,使用查詢,以及,引號住完整查詢。For a name, use QueryString, and for a value, enclose the full query in quotation marks.

如需詳細資訊,請查看運作方式叢集更新插For more information, see How Cluster-Aware Updating plug-ins work.

指定您要求更新執行選項 Options that you specify when you request an Updating Run

下表列出您要求更新執行時,您可以指定(以外這些更新執行設定檔)的選項。The following table lists options (other than those in an Updating Run Profile) that you can specify when you request an Updating Run. 您可以設定更新執行設定檔的選項的相關資訊,會看到上述表格。For information about options that you can set in an Updating Run Profile, see the preceding table.

選項Option 預設值。Default value 詳細資料Details
ClusterNameClusterName None
注意: CAU UI 不執行容錯移轉叢集節點中,或您想要參考容錯移轉叢集不同 CAU UI 在何處執行時才必須設定此選項。Note: This option must be set only when the CAU UI is not run on a failover cluster node, or you want to reference a failover cluster different from where the CAU UI is run.
在其上執行更新執行叢集 NetBIOS 名稱。NetBIOS name of the cluster on which to perform the Updating Run.
認證Credential 目前 account 認證Current account credentials 管理權限目標叢集更新執行將會執行。Administrative credentials for the target cluster on which the Updating Run will be performed. 您可能已經必要的認證如果開始 CAU UI(或打開 PowerShell 工作階段,如果您正在使用 CAU PowerShell cmdlet)叢集具有系統管理員權限 account 從。You may already have the necessary credentials if you start the CAU UI (or open a PowerShell session, if you're using the CAU PowerShell cmdlets) from an account that has administrator rights and permissions on the cluster.
NodeOrderNodeOrder 根據預設,CAU 開頭擁有小數目叢集的角色,然後進行到的第二小的數字和等等節點節點。By default, CAU starts with the node that owns the smallest number of clustered roles, then progresses to the node that has the second smallest number, and so on. 叢集節點,其應該更新(如果可能的話)的順序的名稱。Names of the cluster nodes in the order that they should be updated (if possible).

使用更新執行設定檔 Use Updating Run Profiles

每個更新執行可以相關聯的特定更新執行的設定檔。Each Updating Run can be associated with a specific Updating Run Profile. 預設的更新執行的個人檔案儲存在%windir%\cluster資料夾。The default Updating Run Profile is stored in the %windir%\cluster folder. 如果您使用 CAU UI 遠端更新模式,您可以指定更新執行設定檔,適用於更新的時間,或者您可以使用的預設更新執行設定檔。If you're using the CAU UI in remote-updating mode, you can specify an Updating Run Profile at the time that you apply updates, or you can use the default Updating Run profile. 如果您正在使用 CAU 自我更新模式中,您可以匯入的設定指定更新執行的設定檔當您在設定自動更新的選項。If you're using CAU in self-updating mode, you can import the settings from a specified Updating Run Profile when you configure the self-updating options. 在這兩個案例中,您可以依據您的需求覆寫顯示的值對更新執行選項。In both cases, you can override the displayed values for the Updating Run options according to your needs. 如果您想,您可以將儲存的更新執行選項更新執行設定檔相同的檔案名稱或其他檔案名稱。If you want, you can save the Updating Run options as an Updating Run Profile with the same file name or a different file name. 下次您適用的更新,或設定自動更新的選項,CAU 自動選取更新執行設定檔先前選取。The next time that you apply updates or configure self-updating options, CAU automatically selects the Updating Run Profile that was previously selected.

您可以修改現有更新執行的設定檔,或建立新的 homegroup,選取 [建立修改更新執行設定檔或在 CAU UI 中。You can modify an existing Updating Run Profile or create a new one by selecting Create or modify Updating Run Profile in the CAU UI.

以下是一些有關使用更新執行設定檔的重要事項:Here are some important notes about using Updating Run Profiles:

  • 更新執行設定檔不會儲存叢集特定資訊,例如系統管理員認證。An Updating Run Profile doesn't store cluster-specific information such as administrative credentials. 如果您使用 CAU 自我更新模式,請更新執行設定檔也不會儲存自我更新排程資訊。If you're using CAU in self-updating mode, the Updating Run Profile also doesn't store the self-updating schedule information. 這可讓您可以在所有容錯指定課程中分享更新執行設定檔。This makes it possible to share an Updating Run Profile across all failover clusters in a specified class.
  • 如果您在設定自動更新使用更新執行設定檔的選項稍後修改使用不同的值對更新執行選項的設定檔,不會自動變更設定自動更新。If you configure self-updating options using an Updating Run Profile and later modify the profile with different values for the Updating Run options, the self-updating configuration doesn't change automatically. 若要套用新的更新執行設定,您必須再試一次設定自動更新的選項。To apply the new Updating Run settings, you must configure the self-updating options again.
  • 執行設定檔編輯器很可惜不支援的檔案路徑包含空間,例如C:\Program 檔案The Run Profile Editor unfortunately doesn't support file paths that include spaces, such as C:\Program Files. 因應措施可用,將您前和更新指令碼文章中不包含空間,或使用 PowerShell 專屬執行設定檔,將路徑引號執行時的路徑叫用-CauRunAs a workaround, store your pre and post update scripts in a path that doesn't include spaces, or use PowerShell exclusively to manage Run Profiles, putting quotes around the path when running Invoke-CauRun.

Windows PowerShell 相同的命令Windows PowerShell equivalent commands

當您執行時,您可以會匯入設定更新執行設定檔叫用-CauRun新增-CauClusterRole,或設定-CauClusterRole cmdlet。You can import the settings from an Updating Run Profile when you run the Invoke-CauRun, Add-CauClusterRole, or Set-CauClusterRole cmdlet.

下列範例執行掃描完整更新上並執行叢集名為CONTOSO-FC1,使用更新執行選項中指定的C:\Windows\Cluster\DefaultParameters.xmlThe following example performs a scan and a full Updating Run on the cluster named CONTOSO-FC1, using the Updating Run options that are specified in C:\Windows\Cluster\DefaultParameters.xml. 剩餘的 cmdlet 參數會使用預設值。Default values are used for the remaining cmdlet parameters.

$MyRunProfile = Import-Clixml C:\Windows\Cluster\DefaultParameters.xml  
Invoke-CauRun –ClusterName CONTOSO-FC1 @MyRunProfile   

使用更新執行設定檔,您可以設定一致例外管理、時間範圍,以及其他操作參數更新容錯移轉叢集中重複的方式。By using an Updating Run Profile, you can update a failover cluster in a repeatable fashion with consistent settings for exception management, time bounds, and other operational parameters. 因為通常是一種容錯特定這些設定,例如「所有 Microsoft SQL Server 叢集」或「我關鍵性叢集」,您可能想要為每個更新執行設定檔依據種容錯它將會搭配。Because these settings are typically specific to a class of failover clusters—such as “All Microsoft SQL Server clusters”, or “My business-critical clusters”—you might want to name each Updating Run Profile according to the class of Failover Clusters it will be used with. 此外,您可能想要管理更新執行上的設定檔的無障礙的容錯特定課程 IT 組織中的所有檔案共用。In addition, you might want to manage the Updating Run Profile on a file share that is accessible to all of the failover clusters of a specific class in your IT organization.

也了See also