Ansible Connection from Ubuntu to Windows (using WinRM)

Anonymous
2024-05-23T10:37:02+00:00

I want to connect through 20 windows machine using my Ubuntu machine (controller node)

In my Ubuntu machine I have ansible installed and I need to connect the above 20 Windows machines (I have info like IP, Hostname, Userid, Password) using Kerberos Authentication since all the machines are under single domain network. And Basic, Certificate all the other methods are disabled by "GPO". Only using Kerberos.

I am able to connect through the 2 Machines because I have explicitly Enabled WinRM.. like "WinRM qc" and then added HTTPS 5986 port

But I don't want to go to each and every machine and enable WinRM separately, instead create a script that does enabling WinRM, opening ports, allowing traffic etc by itself. No physical intervention at all. And everything using Ubuntu machine which has Ansible.

* Changed to a question

***moved from Windows / Windows 11 / Internet and connectivity***

Windows for business Windows Client for IT Pros Networking Network connectivity and file sharing

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question. To protect privacy, user profiles for migrated questions are anonymized.

0 comments No comments
{count} vote

1 answer

Sort by: Most helpful
  1. Anonymous
    2024-05-27T07:47:39+00:00

    Hello,

    Since the scripting service is beyond the scope of support, it can provide you with command support. You can refer to the following CMD implementation.

    #Quickly configure the WinRM service, including opening WinRM and opening firewall anomaly detection, HTTPS transmission, port 5986

    winrm quickconfig -transport:https

    Best regards

    Zunhui

    0 comments No comments