Error we get in PowerShell : |
Starting a command on remote server failed with the following error message : The WinRM client sent a request to the re mote WS-Management service and was notified that the request size exceeded the configured MaxEnvelopeSize quota. For mo re information, see the about_Remote_Troubleshooting Help topic. + CategoryInfo : OperationStopped: (System.Manageme…pressionSyncJob:PSInvokeExpressionSyncJob) [], PSRe motingTransportException + FullyQualifiedErrorId : JobFailure |
Too many entries? Maybe just a GUI error let us try in PowerShell. Here is HOW to add an additional IP address to the existing Network Relay Connector. (A new one).
DUMP all receive Connectors into file:
Get-ReceiveConnector “butschcas2\RELAY_SERVER” | Ft remoteipranges -autosize | out-string -width 4096 > butschcas2_rc_14.08.2019.txt
Add a single IP to the Receive connector:
$RecvConn = Get-ReceiveConnector “butschCAS2\RELAY_SERVER”
$RecvConn.RemoteIPRanges += “192.168.5.196”
Set-ReceiveConnector “butschCAS2\RELAY_SERVER” -RemoteIPRanges $RecvConn.RemoteIPRanges
Error we get in PowerShell : |
Starting a command on remote server failed with the following error message : The WinRM client sent a request to the re mote WS-Management service and was notified that the request size exceeded the configured MaxEnvelopeSize quota. For mo re information, see the about_Remote_Troubleshooting Help topic. + CategoryInfo : OperationStopped: (System.Manageme…pressionSyncJob:PSInvokeExpressionSyncJob) [], PSRe motingTransportException + FullyQualifiedErrorId : JobFailure |
HERE is how to fix:
Check a value with:
winrm get winrm/config
It is now 500KB
The DAG Mailbox Server had a value of 500
The two CAS Server had a value of 150
We assume this was changed by some MDM like Air watch or Blackberry or even the Archive solution Symantec EV. Just some software installation which had the permission to run a PowerShell on the server.
Change this to a higher value like 2048KB
winrm set winrm/config @{MaxEnvelopeSizekb=”8192″}
Check the value again
winrm get winrm/config
Open the web.config file for PowerShell on the CAS Server:
Make a BACKUP (You can do this while IIS and exchange are running)
D:\Program Files\Microsoft\Exchange Server\V14\ClientAccess\PowerShell\web.config
Search and change
OLD:
<OperationsConfiguration MaxOperationTimeoutSeconds=”900″ MaxShellIdleTimeoutMinutes=”15″ />
NEW:
<OperationsConfiguration MaxOperationTimeoutSeconds=”900″ MaxShellIdleTimeoutMinutes=”15″ MaxEnvelopeSizeKB=”8192″/>
SAVE and do an IISRESET or Restart Server
Now:
You will have to synchronize this value on all you Exchange Servers. Depending on WHERE you RUN a PowerShell or open GUI (Mailboxen-DAG, CAS, Managemetn JUMPHOST with Exchange Console etc.)
Even if you would have, an Automation Server with the Exchange PowerShell ADDON’s installed?