Bug 1624284

Summary: Meet 'openshift_is_atomic' is undefined during execute CNS standalone deployment playbook with glusterfs group
Product: OpenShift Container Platform Reporter: Wenkai Shi <weshi>
Component: InstallerAssignee: Jose A. Rivera <jarrpa>
Status: CLOSED CURRENTRELEASE QA Contact: Johnny Liu <jialiu>
Severity: medium Docs Contact:
Priority: medium    
Version: 3.11.0CC: aos-bugs, jokerman, mmccomas, nberry, wsun
Target Milestone: ---   
Target Release: 3.11.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: No Doc Update
Doc Text:
undefined
Story Points: ---
Clone Of:
: 1628902 (view as bug list) Environment:
Last Closed: 2018-12-21 15:23:42 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:
Bug Depends On:    
Bug Blocks: 1628902    

Description Wenkai Shi 2018-08-31 07:31:53 UTC
Description of problem:
Meet 'openshift_is_atomic' is undefined during execute CNS standalone deployment playbook with glusterfs group.

Version-Release number of the following components:
openshift-ansible-3.11.0-0.25.0.git.0.7497e69.el7.noarch
ansible-2.6.3-1.el7ae.noarch

How reproducible:
100%

Steps to Reproduce:
1. Deploy OCP with there extra node(for CNS)
2. Defined glusterfs group in inventory file, execute CNS standalone deployment playbook.
3.

Actual results:
# ansible-playbook -i inventory -vv /usr/share/ansible/openshift-ansible/playbooks/openshift-glusterfs/config.yml
...
TASK [openshift_node : Install GlusterFS storage plugin dependencies] ************************************************************************************************************************
task path: /usr/share/ansible/openshift-ansible/roles/openshift_node/tasks/glusterfs.yml:2
Friday 31 August 2018  14:46:03 +0800 (0:00:02.128)       0:00:47.047 ********* 
fatal: [qe-weshi-node-registry-router-1.0831-fug.qe.rhcloud.com]: FAILED! => {"msg": "The conditional check 'not openshift_is_atomic | bool' failed. The error was: error while evaluating conditional (not openshift_is_atomic | bool): 'openshift_is_atomic' is undefined\n\nThe error appears to have been in '/usr/share/ansible/openshift-ansible/roles/openshift_node/tasks/glusterfs.yml': line 2, column 3, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n---\n- name: Install GlusterFS storage plugin dependencies\n  ^ here\n"}
fatal: [qe-weshi-node-1.0831-fug.qe.rhcloud.com]: FAILED! => {"msg": "The conditional check 'not openshift_is_atomic | bool' failed. The error was: error while evaluating conditional (not openshift_is_atomic | bool): 'openshift_is_atomic' is undefined\n\nThe error appears to have been in '/usr/share/ansible/openshift-ansible/roles/openshift_node/tasks/glusterfs.yml': line 2, column 3, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n---\n- name: Install GlusterFS storage plugin dependencies\n  ^ here\n"}
ok: [qe-weshi-master-etcd-1.0831-fug.qe.rhcloud.com] => {"attempts": 1, "changed": false, "msg": "", "rc": 0, "results": ["glusterfs-fuse-3.8.4-54.15.el7.x86_64 providing glusterfs-fuse is already installed"]}
ok: [qe-weshi-glusterfs-node-1.0831-fug.qe.rhcloud.com] => {"attempts": 1, "changed": false, "msg": "", "rc": 0, "results": ["glusterfs-fuse-3.8.4-54.15.el7.x86_64 providing glusterfs-fuse is already installed"]}
ok: [qe-weshi-glusterfs-node-3.0831-fug.qe.rhcloud.com] => {"attempts": 1, "changed": false, "msg": "", "rc": 0, "results": ["glusterfs-fuse-3.8.4-54.15.el7.x86_64 providing glusterfs-fuse is already installed"]}
ok: [qe-weshi-glusterfs-node-2.0831-fug.qe.rhcloud.com] => {"attempts": 1, "changed": false, "msg": "", "rc": 0, "results": ["glusterfs-fuse-3.8.4-54.15.el7.x86_64 providing glusterfs-fuse is already installed"]}
...
PLAY RECAP ***********************************************************************************************************************************************************************************
localhost                  : ok=12   changed=0    unreachable=0    failed=0   
qe-weshi-glusterfs-node-1.0831-fug.qe.rhcloud.com : ok=22   changed=7    unreachable=0    failed=0   
qe-weshi-glusterfs-node-2.0831-fug.qe.rhcloud.com : ok=22   changed=7    unreachable=0    failed=0   
qe-weshi-glusterfs-node-3.0831-fug.qe.rhcloud.com : ok=22   changed=7    unreachable=0    failed=0   
qe-weshi-master-etcd-1.0831-fug.qe.rhcloud.com : ok=105  changed=36   unreachable=0    failed=0   
qe-weshi-node-1.0831-fug.qe.rhcloud.com : ok=1    changed=0    unreachable=0    failed=1   
qe-weshi-node-registry-router-1.0831-fug.qe.rhcloud.com : ok=1    changed=0    unreachable=0    failed=1   

Expected results:
Shouldn't meet var undefined error.

Additional info:

Comment 3 Jose A. Rivera 2018-08-31 15:39:48 UTC
This PR should help solve the issue: https://github.com/openshift/openshift-ansible/pull/9847

Comment 5 Jose A. Rivera 2018-09-06 17:16:22 UTC
PR merged.

Comment 6 Wei Sun 2018-09-10 08:41:20 UTC
The PR 9847 has been merged to openshift-ansible-3.11.0-0.29.0,please check if it could be verified.

Comment 8 Wenkai Shi 2018-09-14 03:35:10 UTC
Verified with version openshift-ansible-3.11.4-1.git.0.d727082.el7_5.noarch, it has been fixed.

# ansible-playbook -i inventory -vv /usr/share/ansible/openshift-ansible/playbooks/openshift-glusterfs/config.yml
...
TASK [openshift_node : Install GlusterFS storage plugin dependencies] ************************************************************************************************************************
task path: /usr/share/ansible/openshift-ansible/roles/openshift_node/tasks/glusterfs.yml:2
Friday 14 September 2018  11:25:30 +0800 (0:00:00.124)       0:00:46.642 ****** 
ok: [qe-weshi-cns-node-registry-router-1.0914-wrl.qe.rhcloud.com] => {"attempts": 1, "changed": false, "msg": "", "rc": 0, "results": ["glusterfs-fuse-3.8.4-54.15.el7.x86_64 providing glusterfs-fuse is already installed"]}
ok: [qe-weshi-cns-master-etcd-1.0914-wrl.qe.rhcloud.com] => {"attempts": 1, "changed": false, "msg": "", "rc": 0, "results": ["glusterfs-fuse-3.13.2-2.el7.x86_64 providing glusterfs-fuse is already installed"]}
ok: [qe-weshi-cns-node-1.0914-wrl.qe.rhcloud.com] => {"attempts": 1, "changed": false, "msg": "", "rc": 0, "results": ["glusterfs-fuse-3.8.4-54.15.el7.x86_64 providing glusterfs-fuse is already installed"]}
ok: [qe-weshi-cns-glusterfs-node-1.0914-wrl.qe.rhcloud.com] => {"attempts": 1, "changed": false, "msg": "", "rc": 0, "results": ["glusterfs-fuse-3.8.4-54.15.el7.x86_64 providing glusterfs-fuse is already installed"]}
ok: [qe-weshi-cns-glusterfs-node-2.0914-wrl.qe.rhcloud.com] => {"attempts": 1, "changed": false, "msg": "", "rc": 0, "results": ["glusterfs-fuse-3.8.4-54.15.el7.x86_64 providing glusterfs-fuse is already installed"]}
ok: [qe-weshi-cns-glusterfs-node-3.0914-wrl.qe.rhcloud.com] => {"attempts": 1, "changed": false, "msg": "", "rc": 0, "results": ["glusterfs-fuse-3.8.4-54.15.el7.x86_64 providing glusterfs-fuse is already installed"]}
...

Comment 10 Luke Meyer 2018-12-21 15:23:42 UTC
Closing bugs that were verified and targeted for GA but for some reason were not picked up by errata. This bug fix should be present in current 3.11 release content.