2
votes

I would like to connect to Exchange Server 2010 by using PowerShell.

I am using the following command:

PS C:\Windows\system32> $UserCredential = Get-Credential

PS C:\Windows\system32> $Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://<serverName>/powershell-liveid/ -Credential $UserCredential -Authenticat

At this point I got the following error message:

WARNING: Your connection has been redirected to the following URI: "https://****************/owa/pow ershell-liveid " New-PSSession : [******************] Connecting to remote server **************** failed with the following error message : The WinRM client received an HTTP status code of 440 from the remote WS-Management service. For more information, see the about_Remote_Troubleshooting Help topic. At line:1 char:12 + $Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri ht ... + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : OpenError: (System.Manageme....RemoteRunspace:RemoteRunspace) [New-PSSession], PSRemotingTransportException + FullyQualifiedErrorId : -2144108273,PSSessionOpenFailed

I have tried to search for this 440 Error and figure out what is the exact cause for this error, but got no result. Could anyone please give some ideas about why it fails and how to fix it?

1

1 Answers

0
votes

On all the exchange servers that I manage the uri is http://EXCHANGESERVERfqdn/PowerShell