Issue in making Remote powershell connection from windows 7

0

I am trying to make persistant remote powershell connection from Windows7(32-bit) to exchange Server 2013,such that I can run some powershell commands from My windows7 machine as i am running it on server. I am following steps from this article https://technet.microsoft.com/en-us/library/dd335083(v=exchg.150).aspx

I had already installed .net Framework Version 4.5, Windows Framework 4.0, and windows already has SP1 installed.

Now, the issue is in running this command


$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri http://ServerName.domain.com/PowerShell/ -Authentication Kerberos -Credential $UserCredential

Everytime it results into an error that is

New-PSSession : [ex13r.corp.local] Connecting to remote server ex13r.corp.local failed with the following error message : WinRM cannot process the request. The following error with errorcode 0x80090311 occurred while using Kerberos authentication: There are currently no logon servers available to service the logon request. Possible causes are: -The user name or password specified are invalid. -Kerberos is used when no authentication method and no user name are specified. -Kerberos accepts domain user names, but not local user names. -The Service Principal Name (SPN) for the remote computer name and port does not exist. -The client and remote computers are in different domains and there is no trust between the two domains. After checking for the above issues, try the following: -Check the Event Viewer for events related to authentication. -Change the authentication method; add the destination computer to the WinRM TrustedHosts configuration setting or use HTTPS transport. Note that computers in the TrustedHosts list might not be authenticated. -For more information about WinRM configuration, run the following command: winrm help config. For more information, see the about_Remote_Troubleshooting Help topic. At D:\path.ps1:1 char:10 + $session=New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri http ... + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : OpenError: (System.Manageme....RemoteRunspace:RemoteRunspace) [New-PSSession], PSRemotin gTransportException + FullyQualifiedErrorId : AuthenticationFailed,PSSessionOpenFailed

NOTE Client machine(Windows7) is not connected to any domain

  1. I added the server to the list of trustedHosts

  2. Set-ExecutionPolicy to remotesigned

  3. Winrm service is also running.

  4. Windows firewall is turned off on both the systems.

My Powershell Configuration after framework 4.0 installation is as follows


Name                           Value
---- -----
PSVersion 4.0
WSManStackVersion 3.0
SerializationVersion 1.1.0.1
CLRVersion 4.0.30319.18408
BuildVersion 6.3.9600.16406
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0}
PSRemotingProtocolVersion 2.2

My efforts are going in no direction,the error remains the same.Any help would greatly be appreciated. Thanks!

powershell-remoting
asked on Stack Overflow Feb 5, 2018 by Pant

0 Answers

Nobody has answered this question yet.


User contributions licensed under CC BY-SA 3.0