Set-SPRoutingMachinePool

コンピューター プールのプロパティを設定します。

構文

Set-SPRoutingMachinePool
   [-Identity] <SPRoutingMachinePoolPipeBind>
   [-AssignmentCollection <SPAssignmentCollection>]
   [-MachineTargets <SPRoutingRuleTargetPipeBind[]>]
   [<CommonParameters>]

説明

コマンドレットを Set-SPRoutingMachinePool 使用して、Identity パラメーターを使用してマシン プールのプロパティを設定します。

Windows PowerShell for SharePoint 製品のアクセス許可と最新情報については、「SharePoint Server コマンドレット」のオンライン ドキュメントをご覧ください。

-------------------- 例 ---------------------

$wa = Get-SPWebApplication -Identity https://webAppUrl
$rm = Get-SPRequestManagementSettings -Identity $wa
$pool = Get-SPRoutingMachinePool -RequestManagementSettings $rm -Name 'MachinePool'
$newMachine = Get-SPRoutingMachineInfo -RequestManagementSettings $rm -Name SP01
Set-SPRoutingMachinePool -Identity $pool -MachineTargets ($pool.MachineTargets + $newMachine)

次の使用例は、指定した Web アプリケーションのルーティング マシン プールを設定します。 Web アプリケーションの要求管理設定を使用して、'MachinePool' という名前の既存のルーティング マシン プールを取得します。 その後、プールに追加する新しいマシンのルーティング マシン情報を取得します。 最後に、既存のマシン ターゲットと新しいマシン ターゲットを含むプールを設定します。

パラメーター

-AssignmentCollection

適切な破棄を行うためにオブジェクトを管理します。 SPWeb や SPSite などのオブジェクトの使用によって大量のメモリが使用される場合があるので、Windows PowerShell スクリプトでこれらのオブジェクトを使用するには適切なメモリ管理が必要です。 メモリの解放が必要になった場合は、SPAssignment オブジェクトを使用して、変数へのオブジェクトの割り当てとオブジェクトの破棄を行うことができます。 割り当てコレクションまたは Global パラメーターが使用されていない場合、SPWeb、SPSite、または SPSiteAdministration オブジェクトが使用されていると、オブジェクトは自動的に破棄されます。

Global パラメーターが使用されている場合は、オブジェクトはすべてグローバル ストアに格納されます。 Stop-SPAssignment コマンドを使用してオブジェクトの使用または破棄を直接行わないと、メモリ不足のシナリオになる場合があります。

Type:SPAssignmentCollection
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False
Applies to:SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019

-Identity

設定する要求管理設定オブジェクトの名前を指定します。

Type:SPRoutingMachinePoolPipeBind
Position:1
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False
Applies to:SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019

-MachineTargets

コンピューター プールに含めるルーティング ターゲット コレクションを指定します。

Type:SPRoutingRuleTargetPipeBind[]
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False
Applies to:SharePoint Server 2013, SharePoint Server 2016, SharePoint Server 2019