# win\_unzip hanging

**URL:** <https://forum.ansible.com/t/win-unzip-hanging/18770>\
**Category:** Ansible Project\
**Tags:** windows\
**Created:** [July 15, 2015, 11:24am UTC](https://forum.ansible.com/t/win-unzip-hanging/18770 "2015-07-15T11:24:53Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Guillaume\_Querso](https://avatars.discourse-cdn.com/v4/letter/g/cdc98d/32.png) [@Guillaume\_Querso](https://forum.ansible.com/u/Guillaume_Querso)\
**Post date:** [July 15, 2015, 11:24am UTC](https://forum.ansible.com/t/win-unzip-hanging/18770/1 "2015-07-15T11:24:53Z")

</div>

hi all,

I am using ansible to unzip files on a windows 2008 R2 server. My playbook was working fine but for an unknown reason, the win\_unzip module is now never ending. i am running ansible 1.9.2.  
Thank you for your help!!

---

<div class="post-metadata">

**Author:** ![j.r.hawkesworth](https://avatars.discourse-cdn.com/v4/letter/j/a3d4f5/32.png) [@j.r.hawkesworth](https://forum.ansible.com/u/j.r.hawkesworth)\
**Post date:** [July 15, 2015, 1:53pm UTC](https://forum.ansible.com/t/win-unzip-hanging/18770/2 "2015-07-15T13:53:36Z")

</div>

Hi Guillaume,

A few things you could try.

Run with -vvvvv to see if the module is being run.

2/ set  
ANSIBLE\_KEEP\_REMOTE\_FILES=1 on your controller before running your playbook.

This will then not delete the powershell scripts so you can log into the affected machine and run them directly in powershell

3/ check event log for errors.

Hopefully you can find out what the problem is using the above.

Jon

---

<div class="post-metadata">

**Author:** ![Guillaume\_Querso](https://avatars.discourse-cdn.com/v4/letter/g/cdc98d/32.png) [@Guillaume\_Querso](https://forum.ansible.com/u/Guillaume_Querso)\
**Post date:** [July 16, 2015, 11:16am UTC](https://forum.ansible.com/t/win-unzip-hanging/18770/3 "2015-07-16T11:16:28Z")

</div>

hi jon,

unfortunately, nothing works to solve the problem… is there anything new on the domain access? because it would make things a lot easier for me (and the windows community)!!!

Thanks

---

<div class="post-metadata">

**Author:** ![Derek\_Viljoen](https://avatars.discourse-cdn.com/v4/letter/d/919ad9/32.png) [@Derek\_Viljoen](https://forum.ansible.com/u/Derek_Viljoen)\
**Post date:** [August 16, 2016, 8:01pm UTC](https://forum.ansible.com/t/win-unzip-hanging/18770/4 "2016-08-16T20:01:28Z")

</div>

I’ve got the same problem. It is because the Expand-Archive command in the generated powershell script prompts the user to overwrite an existing file/directory. I’ve opened another thread asking if anyone knows how to force it to overwrite without prompting.

---

<div class="post-metadata">

**Author:** ![j.r.hawkesworth](https://avatars.discourse-cdn.com/v4/letter/j/a3d4f5/32.png) [@j.r.hawkesworth](https://forum.ansible.com/u/j.r.hawkesworth)\
**Post date:** [August 22, 2016, 1:26pm UTC](https://forum.ansible.com/t/win-unzip-hanging/18770/5 "2016-08-22T13:26:22Z")

</div>

Would it be possible to use win\_file state: absent first? I don’t know what problem you are trying to solve but its a pattern I use, which I like as that way I know the contents of an unzipped folder only contains the things in my zip, thereby enforcing that my playbook remains in control of what is left on my managed hosts.

Jon
