Starting application pool concurrently causes erro

2019-07-22 18:06发布

I have a powershell script which can run asynchorusly to start multiple application pools.

But when i have a certain amount of app pools to start it throws the following error:

The running command stopped because the preference variable "ErrorActionPreference" or common parameter is set to Stop: [ServerX] Connecting to remote server XXX failed with the following error message : The WS-Management service cannot process the request. This user has exceeded the maximum number of concurrent shells allowed for this plugin. Close at least one open shell or raise the plugin quota for this user. For more information, see the about_Remote_Troubleshooting Help topic.

The maximum shells per user is 10000.

It seems that there is more happening beneath the hood when appcmd runs but not sure how i can get around this issue

Any advice would be great

Below is the winrs config

Type            Name                           SourceOfValue   Value
----            ----                           -------------   -----
System.String   AllowRemoteShellAccess                         true
System.String   IdleTimeout                                    7200000
System.String   MaxConcurrentUsers                             10
System.String   MaxShellRunTime                                2147483647
System.String   MaxProcessesPerShell                           25
System.String   MaxMemoryPerShellMB                            1024
System.String   MaxShellsPerUser                               10000

1条回答
Animai°情兽
2楼-- · 2019-07-22 18:27
cd WSMan:\localhost\Shell
Set-Item .\MaxProcessesPerShell 10000
查看更多
登录 后发表回答