# Cannot delegate task to a windows host anymore

**URL:** <https://forum.ansible.com/t/cannot-delegate-task-to-a-windows-host-anymore/37002>\
**Category:** AWX Project\
**Tags:** windows, awx, ee\
**Created:** [August 18, 2022, 5:48am UTC](https://forum.ansible.com/t/cannot-delegate-task-to-a-windows-host-anymore/37002 "2022-08-18T05:48:29Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Julien\_Lejeune](https://avatars.discourse-cdn.com/v4/letter/j/6bbea6/32.png) [@Julien\_Lejeune](https://forum.ansible.com/u/Julien_Lejeune)\
**Post date:** [August 18, 2022, 5:48am UTC](https://forum.ansible.com/t/cannot-delegate-task-to-a-windows-host-anymore/37002/1 "2022-08-18T05:48:29Z")

</div>

Hello all,

I encounter a problem with my AWX instances and I was redirected here after opening an issue in the awx-ee project on Github.

Problem  
I can’t delegate tasks to Windows host anymore.  
This problem occurs a week ago approximately.  
Also, I am totally able to run a task on a Windows host, only delegated tasks are an issue. So the host is reachable from AWX.

Context  
I have two AWX instances (see detail below), one was installed why I encounter the problem, but the first has been working for month without a problem.

I also have an Ansible server who can still run tasks delegated to a Windows host. So Windows configuration does not seem to be the issue.

Here I the things I did to fix the problem :

- Disable firewall on Windows host in case it was a connectivity issue.
- When firewall was active, allowing “edge traversal” on the rule in case the firewall didn’t like traffic from OKD/AWX.
- Declare the host in inventory using its FQDN (default was shortname) in case it was a name resolution problem.
- Declare the host in inventory using its IP address (default was shortname) in case it was a name resolution problem.
- Updating and rebooting the Windows host in case it was a name Windows weirdness.

At this point, I assume this is a bug introduced by a recent update. The only “moving part” I see would be this execution environment which is often updated. That’s why I opened an issue on the project in the first place.

Environment  
First env :

- AWX version: 19.5.0

- AWX deployment target: OKD 4.8

- This instance could run tasks on a Windows host before.  
Second env :

- AWX version: 21.4.0

- AWX deployment target: OKD 4.11

- This instance was installed when the problem was detected.

The windows host uses the following parameters:

- ansible\_connection: winrm
- ansible\_port: 5985
- ansible\_winrm\_transport: ntlm
- become\_method: runas
- user and password are set to an active user with the proper rights.

Steps to reproduce

Run any job delegated to a Windows host.  
In my case, i use the module “community.windows.win\_dns\_record” to add a DNS record in Active Directory.

Expected results  
The task should run without any problems.

Actual results  
Task output :  
`ntlm: HTTPConnectionPool(host='XXXX ', port=5985): Max retries exceeded with url: /wsman (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7fa7da5c36a0>: Failed to establish a new connection: [Errno 113] No route to host'))",`

Where XXXX is the targeted host and not the host the task is delegated to.
