hybrid agent error - Win RM issue

dirkdigs 921 Reputation points
2021-05-18T15:22:36.81+00:00

I cannot get hybrid agent to run - i get an error relating to WinRm service .
I checked service and it is running .
97575-2021-05-18-9-28-37.png

I found my error message listed here
https://learn.microsoft.com/en-us/exchange/troubleshoot/administration/connecting-remote-server-failed

However when I go to run the EMT shooter PowerShell script o now am getting this error
97611-2021-05-18-10-21-34.png

Exchange Online
Exchange Online
A Microsoft email and calendaring hosted service.
6,182 questions
Exchange | Exchange Server | Management
Exchange | Hybrid management
0 comments No comments
{count} votes

4 answers

Sort by: Most helpful
  1. Amit Singh 5,306 Reputation points
    2021-05-18T16:12:42.06+00:00

    The connection error can be caused by many different reasons. The problem is usually related to an invalid or incomplete configuration of either the source or target environment. The most common causes for those errors include:

    • The target server is not accepting incoming PowerShell connections.
    • You use an old PowerShell version in either the source or target environment.
    • The source server cannot properly authenticate with the target environment.
    • The WinRM configuration prevents the connection.
    • The network configuration prevents the connection.

    Let me do more research about it and I'll get back to you.

    1 person found this answer helpful.
    0 comments No comments

  2. dirkdigs 921 Reputation points
    2021-05-19T02:26:34.087+00:00

    i tested winrm connectivity from remote computer clearly it is working
    please help . need to migrate to exchange online asap.

    PS C:\Users\Administrator.DOMAIN> Test-WSMan -ComputerName 2014vmmailsrv

    wsmid : http://schemas.dmtf.org/wbem/wsman/identity/1/wsmanidentity.xsd
    ProtocolVersion : http://schemas.dmtf.org/wbem/wsman/1/wsman.xsd
    ProductVendor : Microsoft Corporation
    ProductVersion : OS: 0.0.0 SP: 0.0 Stack: 3.0

    PS C:\Users\Administrator.DOMAIN>

    0 comments No comments

  3. Lucas Liu-MSFT 6,191 Reputation points
    2021-05-19T05:42:21.957+00:00

    Hi @dirkdigs ,

    1. According to the error information provided by EMT Shooter Powershell. Please run the following command in Exchange management shell to check whether Administrator enable the RemotePowershellEnabled. Get-User -Identity <> | Format-List RemotePowerShellEnabled

    2.Please run the following command in Powershell to check the execution policy. In my Exchange hybrid environment, it is "RemoteSigned".

    Get-ExecutionPolicy  
    

    3.Please make sure that the firewall will not block normal communication.

    In addition, in a similar case, I found that IPv6 or related group policies may also cause this error .
    Please refer to: fix-powershell-winrm-remote-connection-errors
    Please Note: Since the web site is not hosted by Microsoft, the link may change without notice. Microsoft does not guarantee the accuracy of this information.


    If the response is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments

  4. dirkdigs 921 Reputation points
    2021-05-19T15:42:27.54+00:00

    [PS] C:\Windows\system32>Get-User -Identity Administrator| Format-List RemotePowerShellEnabled

    RemotePowerShellEnabled : True

    [PS] C:\Windows\system32>Get-ExecutionPolicy
    Unrestricted
    [PS] C:\Windows\system32>

    C:\Windows\system32>winrm qc
    WinRM service is already running on this machine.
    WinRM is already set up for remote management on this computer.

    C:\Windows\system32>winrm e winrm/config/listener
    Listener
    Address = *
    Transport = HTTP
    Port = 5985
    Hostname
    Enabled = true
    URLPrefix = wsman
    CertificateThumbprint
    ListeningOn = 10.132.3.230, 127.0.0.1, ::1, fe80::5efe:10.132.3.230%14, fe80::b517:6dd3:e449:1180%12

    I will try disable IPv6 tonight and see how it goes .


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.