Hmm, just wondering if you are hitting this "On Windows 7 and Server 2008 R2 machines, due to a bug in Windows Management Framework 3.0, it may be necessary to install this hotfix http://support.microsoft.com/kb/2842230 to avoid receiving out of memory and stack overflow exceptions. Newly-installed Server 2008 R2 systems which are not fully up to date with windows updates are known to have this issue."
from documentation here: http://docs.ansible.com/ansible/latest/intro_windows.html#windows-system-prep I'm pretty certain there's no file size limit as such. Worth checking you have latest pywinrm installed as well - later versions are faster. Actually I think there might be another possibility - although I'd expect a different error perhaps. Are you hitting the s2012 and s2008/r2 boxes at the same time? Since you are setting 'flat=yes' the effect of that will be to have fetch try and retrieve the file from multiple servers and write it to a single file, which probably isn't desirable, and even if it were, you'd likely only get one file, or failures due to file locking. Try without 'flat=yes' if that's the case. Jon On Tuesday, July 25, 2017 at 10:07:40 AM UTC+1, Richard Rogers wrote: > > Hi, > Pretty new to Ansible, but enjoying it so far :) > > I have a playbook that connects to a Windows server, creates a zip file of > a specific folder, sub folders and files, then upload to the Ansible server. > > The zip file is 46,588,472 bytes > > When the Windows server is Server 2012 it works correctly. > However, when the server is Server 2008 SP2 or Server 2008 R2 it uploads > 42,467,328 bytes and times out every time. > The following error is raised on the Ansible server (RH 7): > > Traceback (most recent call last): > File > "/usr/lib/python2.7/site-packages/ansible/plugins/connection/winrm.py", > line 513, in fetch_file > result = self._winrm_exec(cmd_parts[0], cmd_parts[1:]) > File > "/usr/lib/python2.7/site-packages/ansible/plugins/connection/winrm.py", > line 261, in _winrm_exec > command_id = self.protocol.run_command(self.shell_id, > to_bytes(command), map(to_bytes, args), console_mode_stdin=(stdin_iterator > is None)) > File "/usr/lib/python2.7/site-packages/winrm/protocol.py", line 276, in > run_command > res = self.send_message(xmltodict.unparse(req)) > File "/usr/lib/python2.7/site-packages/winrm/protocol.py", line 207, in > send_message > return self.transport.send_message(message) > File "/usr/lib/python2.7/site-packages/winrm/transport.py", line 184, in > send_message > response = self.session.send(prepared_request, > timeout=self.read_timeout_sec) > File "/usr/lib/python2.7/site-packages/requests/sessions.py", line 612, > in send > r = adapter.send(request, **kwargs) > File "/usr/lib/python2.7/site-packages/requests/adapters.py", line 490, > in send > raise ConnectionError(err, request=request) > ConnectionError: ('Connection aborted.', error(104, 'Connection reset by > peer')) > > > The Fetch command in the playbook is: > - fetch: > src="S:/TEST/Data/TEST Automation > Staging/test.co.uk-ansible-upload.zip" > dest="/test/ansible/playbooks/test/staging/" > flat=yes > become=false > > Is there some sort of limit in WinRM of around 40Mb (or perhaps a time out > if Server 2012 uploads slightly quicker) for Server 2008 SP2 and Server > 2008 R2, that is raised/removed in Server 2012? > > Any help gratefully appreciated. > > Richie > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/b509b41e-8179-4df9-9e92-f6adab79d487%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
