As an update - here is a -vvvv ansible run via packer extra_arguments. Different failure point - but just illustrates that i can re-run this and have it fail "randomly". Still not sure if its packer, or ansible causing this.
[0;32m qemu: TASK [Configure Registry Key DetectionFrequencyEnabled] ************************ [0m [0;32m qemu: task path: /opt/jenkins/workspace/lates_2016_imagebuild_PR-13-MRQF4SZQDV6W2IPY6NIULRNOV52IVSKY2AZX2JAUYARBUS2VTMNA/windows/ansible/wsus_config.yaml:42 [0m [0;32m qemu: <127.0.0.1> ESTABLISH SSH CONNECTION FOR USER: linux_eng [0m [0;32m qemu: <127.0.0.1> SSH: EXEC ssh -vvv -C -o ControlMaster=auto -o ControlPersist=60s -o StrictHostKeyChecking=no -o Port=44213 -o 'IdentityFile="/tmp/ansible-key223107789"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o User=linux_eng -o ConnectTimeout=10 -o ControlPath=/home/linux_eng/.ansible/cp/b572d0f9f1 127.0.0.1 'PowerShell -NoProfile -NonInteractive -ExecutionPolicy Unrestricted -EncodedCommand UwBlAHQALQBTAHQAcgBpAGMAdABNAG8AZABlACAALQBWAGUAcgBzAGkAbwBuACAATABhAHQAZQBzAHQACgAkAHQAbQBwAF8AcABhAHQAaAAgAD0AIABbAFMAeQBzAHQAZQBtAC4ARQBuAHYAaQByAG8AbgBtAGUAbgB0AF0AOgA6AEUAeABwAGEAbgBkAEUAbgB2AGkAcgBvAG4AbQBlAG4AdABWAGEAcgBpAGEAYgBsAGUAcwAoACcAJQBUAEUATQBQACUAJwApAAoAJAB0AG0AcAAgAD0AIABOAGUAdwAtAEkAdABlAG0AIAAtAFQAeQBwAGUAIABEAGkAcgBlAGMAdABvAHIAeQAgAC0AUABhAHQAaAAgACQAdABtAHAAXwBwAGEAdABoACAALQBOAGEAbQBlACAAJwBhAG4AcwBpAGIAbABlAC0AdABtAHAALQAxADUAMwA3ADIAMQA0ADkAMAAxAC4AMgA5AC0AMQA1ADUANAA5ADEAMgAxADUAMAAzADAAOAA4ADcAJwAKACQAdABtAHAALgBGAHUAbABsAE4AYQBtAGUAIAB8ACAAVwByAGkAdABlAC0ASABvAHMAdAAgAC0AUwBlAHAAYQByAGEAdABvAHIAIAAnACcACgBJAGYAIAAoAC0AbgBvAHQAIAAkAD8AKQAgAHsAIABJAGYAIAAoAEcAZQB0AC0AVgBhAHIAaQBhAGIAbABlACAATABBAFMAVABFAFgASQBUAEMATwBEAEUAIAAtAEUAcgByAG8AcgBBAGMAdABpAG8AbgAgAFMAaQBsAGUAbgB0AGwAeQBDAG8AbgB0AGkAbgB1AGUAKQAgAHsAIABlAHgAaQB0ACAAJABMAEEAUwBUAEUAWABJAFQAQwBPAEQARQAgAH0AIABFAGwAcwBlACAAewAgAGUAeABpAHQAIAAxACAAfQAgAH0A' [0m [0;32m qemu: <127.0.0.1> (0, 'C:\\Users\\<obfuscated>tmp\\AppData\\Local\\Temp\\ansible-tmp-1537214901.29-155491215030887\n', 'OpenSSH_7.4p1, OpenSSL 1.0.2k-fips 26 Jan 2017\r\ndebug1: Reading configuration data /etc/ssh/ssh_config\r\ndebug1: /etc/ssh/ssh_config line 58: Applying options for *\r\ndebug1: auto-mux: Trying existing master\r\ndebug2: fd 3 setting O_NONBLOCK\r\ndebug2: mux_client_hello_exchange: master version 4\r\ndebug3: mux_client_forwards: request forwardings: 0 local, 0 remote\r\ndebug3: mux_client_request_session: entering\r\ndebug3: mux_client_request_alive: entering\r\ndebug3: mux_client_request_alive: done pid = 75800\r\ndebug3: mux_client_request_session: session request sent\r\ndebug1: mux_client_request_session: master session id: 2\r\n#< CLIXML\r\n<Objs Version="1.1.0.1" xmlns="http://schemas.microsoft.com/powershell/2004/04"><Obj S="progress" RefId="0"><TN RefId="0"><T>System.Management.Automation.PSCustomObject</T><T>System.Object</T></TN><MS><I64 N="SourceId">1</I64><PR N="Record"><AV>Preparing modules for first use.</AV><AI>0</AI><Nil /><PI>-1</PI><PC>-1</PC><T>Completed</T><SR>-1</SR><SD> </SD></PR></MS></Obj><Obj S="progress" RefId="1"><TNRef RefId="0" /><MS><I64 N="SourceId">1</I64><PR N="Record"><AV>Preparing modules for first use.</AV><AI>0</AI><Nil /><PI>-1</PI><PC>-1</PC><T>Completed</T><SR>-1</SR><SD> </SD></PR></MS></Obj><Obj S="information" RefId="2"><TN RefId="1"><T>System.Management.Automation.InformationRecord</T><T>System.Object</T></TN><ToString>C:\\Users\\<obfuscated>tmp\\AppData\\Local\\Temp\\ansible-tmp-1537214901.29-155491215030887</ToString><Props><Obj N="MessageData" RefId="3"><TN RefId="2"><T>System.Management.Automation.HostInformationMessage</T><T>System.Object</T></TN><ToString>C:\\Users\\<obfuscated>tmp\\AppData\\Local\\Temp\\ansible-tmp-1537214901.29-155491215030887</ToString><Props><S N="Message">C:\\Users\\<obfuscated>tmp\\AppData\\Local\\Temp\\ansible-tmp-1537214901.29-155491215030887</S><B N="NoNewLine">false</B><S N="ForegroundColor">Gray</S><S N="BackgroundColor">Black</S></Props></Obj><S N="Source">Write-Host</S><DT N="TimeGenerated">2018-09-17T20:08:24.5331624-04:00</DT><Obj N="Tags" RefId="4"><TN RefId="3"><T>System.Collections.Generic.List`1[[System.String, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]]</T><T>System.Object</T></TN><LST><S>PSHOST</S></LST></Obj><S N="User">N2C2016BUILD\\<obfuscated>tmp</S><S N="Computer">N2C2016Build</S><U32 N="ProcessId">3420</U32><U32 N="NativeThreadId">4068</U32><U32 N="ManagedThreadId">10</U32></Props></Obj></Objs>debug3: mux_client_read_packet: read header failed: Broken pipe\r\ndebug2: Received exit status from master 0\r\n') [0m [0;32m qemu: Using module file /usr/lib/python2.7/site-packages/ansible/modules/windows/win_regedit.ps1 [0m [0;32m qemu: <127.0.0.1> PUT /home/linux_eng/.ansible/tmp/ansible-local-75724AP3PCx/tmprmbmal TO 'C:\Users\<obfuscated>tmp\AppData\Local\Temp\ansible-tmp-1537214901.29-155491215030887\win_regedit.ps1' [0m [0;32m qemu: <127.0.0.1> SSH: EXEC scp -vvv -C -o ControlMaster=auto -o ControlPersist=60s -o StrictHostKeyChecking=no -o Port=44213 -o 'IdentityFile="/tmp/ansible-key223107789"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o User=linux_eng -o ConnectTimeout=10 -o ControlPath=/home/linux_eng/.ansible/cp/b572d0f9f1 /home/linux_eng/.ansible/tmp/ansible-local-75724AP3PCx/tmprmbmal '[127.0.0.1]:'"'"''"'"'"'"'"'"'"'"'C:\Users\<obfuscated>tmp\AppData\Local\Temp\ansible-tmp-1537214901.29-155491215030887\win_regedit.ps1'"'"'"'"'"'"'"'"''"'"'' [0m [0;32m qemu: <127.0.0.1> (0, '', 'Executing: program /usr/bin/ssh host 127.0.0.1, user (unspecified), command scp -v -t \'\'"\'"\'C:\\Users\\<obfuscated>tmp\\AppData\\Local\\Temp\\ansible-tmp-1537214901.29-155491215030887\\win_regedit.ps1\'"\'"\'\'\nOpenSSH_7.4p1, OpenSSL 1.0.2k-fips 26 Jan 2017\r\ndebug1: Reading configuration data /etc/ssh/ssh_config\r\ndebug1: /etc/ssh/ssh_config line 58: Applying options for *\r\ndebug1: auto-mux: Trying existing master\r\ndebug2: fd 3 setting O_NONBLOCK\r\ndebug2: mux_client_hello_exchange: master version 4\r\ndebug3: mux_client_forwards: request forwardings: 0 local, 0 remote\r\ndebug3: mux_client_request_session: entering\r\ndebug3: mux_client_request_alive: entering\r\ndebug3: mux_client_request_alive: done pid = 75800\r\ndebug3: mux_client_request_session: session request sent\r\ndebug1: mux_client_request_session: master session id: 2\r\nSending file modes: C0600 52464 tmprmbmal\ndebug3: mux_client_read_packet: read header failed: Broken pipe\r\ndebug2: Received exit status from master 0\r\n') [0m [0;32m qemu: <127.0.0.1> ESTABLISH SSH CONNECTION FOR USER: linux_eng [0m [0;32m qemu: <127.0.0.1> SSH: EXEC ssh -vvv -C -o ControlMaster=auto -o ControlPersist=60s -o StrictHostKeyChecking=no -o Port=44213 -o 'IdentityFile="/tmp/ansible-key223107789"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o User=linux_eng -o ConnectTimeout=10 -o ControlPath=/home/linux_eng/.ansible/cp/b572d0f9f1 -tt 127.0.0.1 'PowerShell -NoProfile -NonInteractive -ExecutionPolicy Unrestricted -EncodedCommand UwBlAHQALQBTAHQAcgBpAGMAdABNAG8AZABlACAALQBWAGUAcgBzAGkAbwBuACAATABhAHQAZQBzAHQACgBUAHIAeQAKAHsACgAmACAAJwBDADoAXABVAHMAZQByAHMAXABwAGEAeQBjAGgAZQB4AHQAbQBwAFwAQQBwAHAARABhAHQAYQBcAEwAbwBjAGEAbABcAFQAZQBtAHAAXABhAG4AcwBpAGIAbABlAC0AdABtAHAALQAxADUAMwA3ADIAMQA0ADkAMAAxAC4AMgA5AC0AMQA1ADUANAA5ADEAMgAxADUAMAAzADAAOAA4ADcAXAB3AGkAbgBfAHIAZQBnAGUAZABpAHQALgBwAHMAMQAnAAoAfQAKAEMAYQB0AGMAaAAKAHsACgAkAF8AbwBiAGoAIAA9ACAAQAB7ACAAZgBhAGkAbABlAGQAIAA9ACAAJAB0AHIAdQBlACAAfQAKAEkAZgAgACgAJABfAC4ARQB4AGMAZQBwAHQAaQBvAG4ALgBHAGUAdABUAHkAcABlACkACgB7AAoAJABfAG8AYgBqAC4AQQBkAGQAKAAnAG0AcwBnACcALAAgACQAXwAuAEUAeABjAGUAcAB0AGkAbwBuAC4ATQBlAHMAcwBhAGcAZQApAAoAfQAKAEUAbABzAGUACgB7AAoAJABfAG8AYgBqAC4AQQBkAGQAKAAnAG0AcwBnACcALAAgACQAXwAuAFQAbwBTAHQAcgBpAG4AZwAoACkAKQAKAH0ACgBJAGYAIAAoACQAXwAuAEkAbgB2AG8AYwBhAHQAaQBvAG4ASQBuAGYAbwAuAFAAbwBzAGkAdABpAG8AbgBNAGUAcwBzAGEAZwBlACkACgB7AAoAJABfAG8AYgBqAC4AQQBkAGQAKAAnAGUAeABjAGUAcAB0AGkAbwBuACcALAAgACQAXwAuAEkAbgB2AG8AYwBhAHQAaQBvAG4ASQBuAGYAbwAuAFAAbwBzAGkAdABpAG8AbgBNAGUAcwBzAGEAZwBlACkACgB9AAoARQBsAHMAZQBJAGYAIAAoACQAXwAuAFMAYwByAGkAcAB0AFMAdABhAGMAawBUAHIAYQBjAGUAKQAKAHsACgAkAF8AbwBiAGoALgBBAGQAZAAoACcAZQB4AGMAZQBwAHQAaQBvAG4AJwAsACAAJABfAC4AUwBjAHIAaQBwAHQAUwB0AGEAYwBrAFQAcgBhAGMAZQApAAoAfQAKAFQAcgB5AAoAewAKACQAXwBvAGIAagAuAEEAZABkACgAJwBlAHIAcgBvAHIAXwByAGUAYwBvAHIAZAAnACwAIAAoACQAXwAgAHwAIABDAG8AbgB2AGUAcgB0AFQAbwAtAEoAcwBvAG4AIAB8ACAAQwBvAG4AdgBlAHIAdABGAHIAbwBtAC0ASgBzAG8AbgApACkACgB9AAoAQwBhAHQAYwBoAAoAewAKAH0ACgBFAGMAaABvACAAJABfAG8AYgBqACAAfAAgAEMAbwBuAHYAZQByAHQAVABvAC0ASgBzAG8AbgAgAC0AQwBvAG0AcAByAGUAcwBzACAALQBEAGUAcAB0AGgAIAA5ADkACgBFAHgAaQB0ACAAMQAKAH0A' [0m [0;32m qemu: <127.0.0.1> (129, '', 'OpenSSH_7.4p1, OpenSSL 1.0.2k-fips 26 Jan 2017\r\ndebug1: Reading configuration data /etc/ssh/ssh_config\r\ndebug1: /etc/ssh/ssh_config line 58: Applying options for *\r\ndebug1: auto-mux: Trying existing master\r\ndebug2: fd 3 setting O_NONBLOCK\r\ndebug2: mux_client_hello_exchange: master version 4\r\ndebug3: mux_client_forwards: request forwardings: 0 local, 0 remote\r\ndebug3: mux_client_request_session: entering\r\ndebug3: mux_client_request_alive: entering\r\ndebug3: mux_client_request_alive: done pid = 75800\r\ndebug3: mux_client_request_session: session request sent\r\ndebug1: mux_client_request_session: master session id: 2\r\n#< CLIXML\r\ndebug3: mux_client_read_packet: read header failed: Broken pipe\r\ndebug2: Received exit status from master 16001\r\nShared connection to 127.0.0.1 closed.\r\n') [0m [0;32m qemu: <127.0.0.1> ESTABLISH SSH CONNECTION FOR USER: linux_eng [0m [0;32m qemu: <127.0.0.1> SSH: EXEC ssh -vvv -C -o ControlMaster=auto -o ControlPersist=60s -o StrictHostKeyChecking=no -o Port=44213 -o 'IdentityFile="/tmp/ansible-key223107789"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o User=linux_eng -o ConnectTimeout=10 -o ControlPath=/home/linux_eng/.ansible/cp/b572d0f9f1 127.0.0.1 'PowerShell -NoProfile -NonInteractive -ExecutionPolicy Unrestricted -EncodedCommand UwBlAHQALQBTAHQAcgBpAGMAdABNAG8AZABlACAALQBWAGUAcgBzAGkAbwBuACAATABhAHQAZQBzAHQACgBSAGUAbQBvAHYAZQAtAEkAdABlAG0AIAAiAEMAOgBcAFUAcwBlAHIAcwBcAHAAYQB5AGMAaABlAHgAdABtAHAAXABBAHAAcABEAGEAdABhAFwATABvAGMAYQBsAFwAVABlAG0AcABcAGEAbgBzAGkAYgBsAGUALQB0AG0AcAAtADEANQAzADcAMgAxADQAOQAwADEALgAyADkALQAxADUANQA0ADkAMQAyADEANQAwADMAMAA4ADgANwAiACAALQBGAG8AcgBjAGUAIAAtAFIAZQBjAHUAcgBzAGUAOwAKAEkAZgAgACgALQBuAG8AdAAgACQAPwApACAAewAgAEkAZgAgACgARwBlAHQALQBWAGEAcgBpAGEAYgBsAGUAIABMAEEAUwBUAEUAWABJAFQAQwBPAEQARQAgAC0ARQByAHIAbwByAEEAYwB0AGkAbwBuACAAUwBpAGwAZQBuAHQAbAB5AEMAbwBuAHQAaQBuAHUAZQApACAAewAgAGUAeABpAHQAIAAkAEwAQQBTAFQARQBYAEkAVABDAE8ARABFACAAfQAgAEUAbABzAGUAIAB7ACAAZQB4AGkAdAAgADEAIAB9ACAAfQA=' [0m [1;31m==> qemu: unknown error Post http://127.0.0.1:2681/wsman: read tcp 127.0.0.1:47302->127.0.0.1:2681: read: connection reset by peer [0m [0;32m qemu: <127.0.0.1> (0, '', 'OpenSSH_7.4p1, OpenSSL 1.0.2k-fips 26 Jan 2017\r\ndebug1: Reading configuration data /etc/ssh/ssh_config\r\ndebug1: /etc/ssh/ssh_config line 58: Applying options for *\r\ndebug1: auto-mux: Trying existing master\r\ndebug2: fd 3 setting O_NONBLOCK\r\ndebug2: mux_client_hello_exchange: master version 4\r\ndebug3: mux_client_forwards: request forwardings: 0 local, 0 remote\r\ndebug3: mux_client_request_session: entering\r\ndebug3: mux_client_request_alive: entering\r\ndebug3: mux_client_request_alive: done pid = 75800\r\ndebug3: mux_client_request_session: session request sent\r\ndebug1: mux_client_request_session: master session id: 2\r\ndebug3: mux_client_read_packet: read header failed: Broken pipe\r\ndebug2: Received exit status from master 0\r\n') [0m [0;32m qemu: fatal: [default]: FAILED! => { [0m [0;32m qemu: "changed": false, [0m [0;32m qemu: "module_stderr": "OpenSSH_7.4p1, OpenSSL 1.0.2k-fips 26 Jan 2017\r\ndebug1: Reading configuration data /etc/ssh/ssh_config\r\ndebug1: /etc/ssh/ssh_config line 58: Applying options for *\r\ndebug1: auto-mux: Trying existing master\r\ndebug2: fd 3 setting O_NONBLOCK\r\ndebug2: mux_client_hello_exchange: master version 4\r\ndebug3: mux_client_forwards: request forwardings: 0 local, 0 remote\r\ndebug3: mux_client_request_session: entering\r\ndebug3: mux_client_request_alive: entering\r\ndebug3: mux_client_request_alive: done pid = 75800\r\ndebug3: mux_client_request_session: session request sent\r\ndebug1: mux_client_request_session: master session id: 2\r\n#< CLIXML\r\ndebug3: mux_client_read_packet: read header failed: Broken pipe\r\ndebug2: Received exit status from master 16001\r\nShared connection to 127.0.0.1 closed.\r\n", [0m [0;32m qemu: "module_stdout": "", [0m [0;32m qemu: "msg": "MODULE FAILURE", [0m [0;32m qemu: "rc": 129 [0m [0;32m qemu: } [0m [0;32m qemu: to retry, use: --limit @/opt/jenkins/workspace/lates_2016_imagebuild_PR-13-MRQF4SZQDV6W2IPY6NIULRNOV52IVSKY2AZX2JAUYARBUS2VTMNA/windows/ansible/wsus_config.retry [0m [0;32m qemu: [0m [0;32m qemu: PLAY RECAP ********************************************************************* [0m [0;32m qemu: default : ok=7 changed=7 unreachable=0 failed=1 [0m [0;32m qemu: [0m [1;32m==> qemu: Deleting output directory... [0m [1;31mBuild 'qemu' errored: Error executing Ansible: Non-zero exit status: exit status 2 [0m ==> Some builds didn't complete successfully and had errors: --> qemu: Error executing Ansible: Non-zero exit status: exit status 2 ==> Builds finished but no artifacts were created. On Monday, September 17, 2018 at 3:41:16 PM UTC-4, Jason Lang wrote: > > Using Packer 1.3.0 to create kvm Windows Server 2016/2012R2 VM's using > ansible 2.6.3 > > I get "random" errors during execution. I can run the same packer run > several time(s) and will get error(s) at different places each time. An > example is below: > > A partial log output is below: > > [1;32m==> qemu: Machine successfully restarted, moving on [0m > [1;32m==> qemu: Provisioning with Ansible... [0m > > [1;32m==> qemu: Executing Ansible: ansible-playbook --extra-vars > packer_build_name=qemu packer_builder_type=qemu -i > /tmp/packer-provisioner-ansible227724354 > /opt/jenkins/workspace/lates_2016_imagebuild_PR-13-MRQF4SZQDV6W2IPY6NIULRNOV52IVSKY2AZX2JAUYARBUS2VTMNA/windows/ansible/wsus_config.yaml > -e ansible_ssh_private_key_file=/tmp/ansible-key136914095 --extra-vars > packer_http_addr=10.0.2.2:8065 --connection packer --extra-vars > ansible_shell_type=powershell ansible_shell_executable=None [0m > > [0;32m qemu: [0m > [0;32m qemu: PLAY [all] > ********************************************************************* [0m > [0;32m qemu: [0m > [0;32m qemu: TASK [Configure Root Registry Key WindowsUpdate] > ******************************* [0m > > [0;32m qemu: changed: [default] [0m > [0;32m qemu: [0m > [0;32m qemu: TASK [Configure Root Registry Key AU] > ****************************************** [0m > > [0;32m qemu: changed: [default] [0m > [0;32m qemu: [0m > [0;32m qemu: TASK [Configure Root Registry Key > CurrentVersionWindowsUpdate] **************** [0m > > [0;32m qemu: changed: [default] [0m > [0;32m qemu: [0m > [0;32m qemu: TASK [Configure Root Registry Key CurrentVersion AU] > *************************** [0m > > [0;32m qemu: changed: [default] [0m > [0;32m qemu: [0m > [0;32m qemu: TASK [Configure Registry Key UseWUServer] > ************************************** [0m > > [0;32m qemu: changed: [default] [0m > [0;32m qemu: [0m > [0;32m qemu: TASK [Configure Registry Key NoAutoUpdate] > ************************************* [0m > > [0;32m qemu: changed: [default] [0m > [0;32m qemu: [0m > [0;32m qemu: TASK [Configure Registry Key DetectionFrequency] > ******************************* [0m > > [0;32m qemu: changed: [default] [0m > [0;32m qemu: [0m > [0;32m qemu: TASK [Configure Registry Key DetectionFrequencyEnabled] > ************************ [0m > > [0;32m qemu: changed: [default] [0m > [0;32m qemu: [0m > [0;32m qemu: TASK [Configure Registry Key AUOptions] > **************************************** [0m > > [0;32m qemu: [WARNING]: Error deleting remote temporary files (rc: 6, > stderr: }) [0m > [0;32m qemu: changed: [default] [0m > [0;32m qemu: [0m > [0;32m qemu: TASK [Configure Registry Key WUServer] > ***************************************** [0m > > [0;32m qemu: fatal: [default]: FAILED! => {"msg": "failed to transfer > file to /home/linux_eng/.ansible/tmp/ansible-local-63783zCgNjm/tmpbX_ouB > 'C:\\Users\\<obfuscated>tmp\\AppData\\Local\\Temp\\ansible-tmp-1537212675.83-235265198325172\\win_regedit.ps1':\n\n\n"} > [0m > [0;32m qemu: to retry, use: --limit > @/opt/jenkins/workspace/lates_2016_imagebuild_PR-13-MRQF4SZQDV6W2IPY6NIULRNOV52IVSKY2AZX2JAUYARBUS2VTMNA/windows/ansible/wsus_config.retry > [0m > [0;32m qemu: [0m > [0;32m qemu: PLAY RECAP > ********************************************************************* [0m > [0;32m qemu: default : ok=9 changed=9 > unreachable=0 failed=1 [0m > [0;32m qemu: [0m > [1;32m==> qemu: Deleting output directory... [0m > [1;31mBuild 'qemu' errored: Error executing Ansible: Non-zero exit status: > exit status 2 [0m > > ==> Some builds didn't complete successfully and had errors: > --> qemu: Error executing Ansible: Non-zero exit status: exit status 2 > > ==> Builds finished but no artifacts were created. > > > My playbook in question looks like: > > > --- > - hosts: all > gather_facts: False > tasks: > - name: Configure Root Registry Key WindowsUpdate > win_regedit: > path: HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate > > - name: Configure Root Registry Key AU > win_regedit: > path: HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU > > - name: Configure Root Registry Key CurrentVersionWindowsUpdate > win_regedit: > path: HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate > > - name: Configure Root Registry Key CurrentVersion AU > win_regedit: > path: > HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update > > - name: Configure Registry Key UseWUServer > win_regedit: > path: HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU > name: UseWUServer > data: 1 > type: dword > > - name: Configure Registry Key NoAutoUpdate > win_regedit: > path: HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU > name: NoAutoUpdate > data: 1 > type: dword > > - name: Configure Registry Key DetectionFrequency > win_regedit: > path: HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU > name: DetectionFrequency > data: 12 > type: dword > > - name: Configure Registry Key DetectionFrequencyEnabled > win_regedit: > path: HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU > name: DetectionFrequencyEnabled > data: 12 > type: dword > > - name: Configure Registry Key AUOptions > win_regedit: > path: HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU > name: AUOptions > data: 2 > type: dword > > - name: Configure Registry Key WUServer > win_regedit: > path: HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate > name: WUServer > data: 'http://wsusapwprh1.<obfuscated>.com:8530' > type: string > > - name: Configure Registry Key WUStatusServer > win_regedit: > path: HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate > name: WUStatusServer > data: 'http://wsusapwprh1.<obfuscated>.com:8530' > type: string > > - name: Configure Registry Key TargetGroup > win_regedit: > path: HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate > name: TargetGroup > data: '<obfuscated>_nonprod' > type: string > > - name: Configure Registry Key TargetGroupEnabled > win_regedit: > path: HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate > name: TargetGroupEnabled > data: 1 > type: dword > > - name: Configure Registry Key NoAutoRebootWithLoggedOnUsers > win_regedit: > path: HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU > name: NoAutoRebootWithLoggedOnUsers > data: 1 > type: dword > > - name: Configure Registry Key RebootRelaunchTimeoutEnabled > win_regedit: > path: HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU > name: RebootRelaunchTimeoutEnabled > data: 1 > type: dword > > - name: Configure Registry Key RebootRelaunchTimeout > win_regedit: > path: HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU > name: RebootRelaunchTimeout > data: 1440 > type: dword > > - name: Configure CurrentVersion Registry Key ForcedReboot > win_regedit: > path: > HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update > name: ForcedReboot > data: 0 > type: dword > > - name: Configure CurrentVersion Registry Key AUOptions > win_regedit: > path: > HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update > name: AUOptions > data: 2 > type: dword > > - name: Configure CurrentVersion Registry Key ElevateNonAdmins > win_regedit: > path: HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate > name: ElevateNonAdmins > data: 0 > type: dword > > Previously i was running this with Packer 1.2.X and ansibe 2.5.2 and it ran > reliably without issue. Is anyone aware of any issues/bugs > with recent packer/ansible versions that might cause this? > > -- This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list. GitHub Issues: https://github.com/mitchellh/packer/issues IRC: #packer-tool on Freenode --- You received this message because you are subscribed to the Google Groups "Packer" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/packer-tool/8deabfc0-c34a-41d9-a765-66bd79cc0c57%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
