Bug 1805513

Summary: [wsu] Running wsu playbook parallelly on 2 windows vm fails
Product: OpenShift Container Platform Reporter: Akhil Rane <arane>
Component: Windows ContainersAssignee: Akhil Rane <arane>
Status: CLOSED ERRATA QA Contact: gaoshang <sgao>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: unspecifiedCC: aos-bugs, gmarkley, rgudimet
Target Milestone: ---   
Target Release: 4.5.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-07-13 17:16:52 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Akhil Rane 2020-02-20 22:22:01 UTC
Description of problem:
When we run wsu playbook parrallely on 2 windows vms, the ansible task 'Move wmcb to temporary directory' fails for the second vm. This is because the run on the first vm has already moved the built wmcb.exe to a temporary directory so run on second vm cannot find it.

Version-Release number of selected component (if applicable):
https://github.com/openshift/windows-machine-config-bootstrapper/commit/0c85e08558f858d9f474caa361c72ad0aa02da7a

How reproducible:
Always

Steps to Reproduce:
1. Install OCP cluster 4.4 with ovn-kubernetes
2. Create 2 Windows nodes
3. Run wsu playbook parallelly on both the Windows Nodes

Actual results:
TASK [Move WMCB to temporary directory] ****************************************
fatal: [localhost]: FAILED! => {"changed": true, "cmd": ["mv", "/home/akhilrane/work/winc-195/windows-machine-config-bootstrapper/tools/ansible/tasks/wsu/../../../../wmcb.exe", "/tmp/ansible.xipyhz8e/wmcb.exe"], "delta": "0:00:00.011613", "end": "2020-02-20 13:42:25.928058", "msg": "non-zero return code", "rc": 1, "start": "2020-02-20 13:42:25.916445", "stderr": "mv: cannot remove '/home/akhilrane/work/winc-195/windows-machine-config-bootstrapper/tools/ansible/tasks/wsu/../../../../wmcb.exe': No such file or directory", "stderr_lines": ["mv: cannot remove '/home/akhilrane/work/winc-195/windows-machine-config-bootstrapper/tools/ansible/tasks/wsu/../../../../wmcb.exe': No such file or directory"], "stdout": "", "stdout_lines": []}

Expected results:
No failures

Additional info:

Comment 3 gaoshang 2020-02-28 06:38:28 UTC
This bug has been verified and passed on OCP 4.4.0-0.nightly-2020-02-26-032705 in AWS, move status to VERIFIED.

Steps to Reproduce:
1. Install OCP cluster 4.4 with ovn-kubernetes
2. Create 2 Windows nodes
3. Run wsu playbook parallelly on both the Windows Nodes

ansible-playbook -i hosts-1 ~/go/src/windows-machine-config-bootstrapper/tools/ansible/tasks/wsu/main.yaml -v > 1.log & ansible-playbook -i hosts-2 ~/go/src/windows-machine-config-bootstrapper/tools/ansible/tasks/wsu/main.yaml -v > 2.log &

Both the 2 ansible run succeed and 2 nodes bootstrapped

Comment 5 errata-xmlrpc 2020-07-13 17:16:52 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2020:2409