Issue when trying to communicate between ansible and windows client

Jayasree K 0 Reputation points
2024-08-27T00:30:40.4733333+00:00

Here is the error: [WARNING]: ERROR DURING WINRM SEND INPUT - attempting to recover: WinRMError The pipe has been ended.

'wsmanfault_code': '109', 'fault_code': 's:Receiver', 'fault_subcode': 'w:InternalError'}) fatal FAILED! => {"msg": "winrm send_input failed; \nstdout: \nstderr "}

Winrm service up and running, listeners configured properly but still this error exists when using transport 5985 and ntlm.

Windows Server 2019
Windows Server 2019
A Microsoft server operating system that supports enterprise-level management updated to data storage.
3,705 questions
Windows Server PowerShell
Windows Server PowerShell
Windows Server: A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.PowerShell: A family of Microsoft task automation and configuration management frameworks consisting of a command-line shell and associated scripting language.
5,508 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Rich Matheisen 46,551 Reputation points
    2024-08-29T16:02:44.1066667+00:00

    WINRM is a Windows (not PowerShell) service. PowerShell makes use of it, though.

    Have you configured WINRM to allow the use of NTLM authentication?

    You can check it like this:

    winrm get winrm/config/service/auth
    

    The result should look like this (NTLM isn't allowed on this machine):

    Auth
        Basic = false
        Kerberos = true
        Negotiate = true
        Certificate = false
        CredSSP = false
        CbtHardeningLevel = Relaxed
    

    You can set it like this:

    winrm set winrm/config/service/auth @{NTLM="true"}
    

    Also, NTLM has multiple versions. What version are you trying to use? I'm pretty sure that the original LM version is disabled and only NTLMV2 is allow. You can change that using a local security polity or by editing the registry directly.

    0 comments No comments

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.