Skip to content

Commit a4d4dfd

Browse files
authored
Merge pull request MicrosoftDocs#647 from tseward/patch-334
Update Set-SPRoutingMachinePool.md
2 parents cdc85d9 + 35a05ca commit a4d4dfd

File tree

1 file changed

+6
-10
lines changed

1 file changed

+6
-10
lines changed

sharepoint/sharepoint-ps/sharepoint-server/Set-SPRoutingMachinePool.md

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -28,17 +28,13 @@ For permissions and the most current information about Windows PowerShell for Sh
2828

2929
### --------------------EXAMPLE---------------------
3030
```
31-
C:\PS>$web=Get-SPWebApplication -Identity <URL of web application>
32-
33-
C:\PS>$rm=Get-SPRequestManagementSettings -Identity $web
34-
35-
C:\PS>$pool=Get-SPRoutingMachinePool -RequestManagementSettings $rm
36-
37-
C:\PS>Set-SPRoutingMachinePool -Identity $pool -MachineTargets <Machine collections>
31+
PS C:\>$wa = Get-SPWebApplication -Identity http://webAppUrl
32+
PS C:\>$rm = Get-SPRequestManagementSettings -Identity $wa
33+
PS C:\>$pool = Get-SPRoutingMachinePool -RequestManagementSettings $rm -Name 'MachinePool'
34+
PS C:\>$newMachine = Get-SPRoutingMachineInfo -RequestManagementSettings $rm -Name SP01
35+
PS C:\>Set-SPRoutingMachinePool -Identity $pool -MachineTargets ($pool.MachineTargets + $newMachine)
3836
```
39-
40-
This example sets the machine pool property of MachineTargets for a specified identity as defined by the $pool variable.
41-
37+
This example sets the routing machine pool on the specified Web Application. Using the Request Management settings of the Web Application, it retrives the existing routing machine pool named 'MachinePool'. It then gets the routing machine info for a new machine to add to the pool. Lastly, it sets the pool with the existing machine targets plus the new machine target.
4238

4339
## PARAMETERS
4440

0 commit comments

Comments
 (0)