Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1537946 - Install CNS fail due to configured check not pass
Install CNS fail due to configured check not pass
Status: CLOSED ERRATA
Product: OpenShift Container Platform
Classification: Red Hat
Component: Installer (Show other bugs)
3.9.0
Unspecified Unspecified
high Severity high
: ---
: 3.9.0
Assigned To: Russell Teague
Wenkai Shi
: TestBlocker
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2018-01-24 02:07 EST by Wenkai Shi
Modified: 2018-03-28 10:22 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Conditional check for openshift_hosted_registry_storage_glusterfs_ips expected an empty string, however, an empty list was presented. Updated the check to expect a list type.
Story Points: ---
Clone Of:
Environment:
Last Closed: 2018-03-28 10:22:32 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2018:0489 None None None 2018-03-28 10:22 EDT

  None (edit)
Description Wenkai Shi 2018-01-24 02:07:17 EST
Description of problem:
Install CNS as docker registry back end storage reference to [1], installation fail in TASK [openshift_sanitize_inventory : Ensure the hosted registry's GlusterFS storage is configured correctly].

[1]. https://github.com/openshift/openshift-ansible/blob/master/inventory/hosts.glusterfs.registry-only.example

Version-Release number of the following components:
openshift-ansible-3.9.0-0.22.0.git.0.0e9d896.el7
ansible-2.4.2.0-2.el7

How reproducible:
100%

Steps to Reproduce:
1. Install CNS 
# cat hosts
[OSEv3:children]
masters
nodes
glusterfs_registry

[OSEv3:vars]
...
openshift_hosted_registry_storage_kind=glusterfs
...

[masters]
master-1.example.com

[nodes]
master-1.example.com
node-1.example.com
glusterfs-1.example.com 
glusterfs-2.example.com 
glusterfs-3.example.com 

[glusterfs_registry]
glusterfs-1.example.com glusterfs_devices="['/dev/vsda']"
glusterfs-2.example.com glusterfs_devices="['/dev/vsda']"
glusterfs-3.example.com glusterfs_devices="['/dev/vsda']"
...

2.
3.

Actual results:
# ansible-playbook -i hosts -v /usr/share/ansible/openshift-ansible/playbooks/prerequisites.yml
...
TASK [openshift_sanitize_inventory : Ensure the hosted registry's GlusterFS storage is configured correctly] ***
Wednesday 24 January 2018  06:05:02 +0000 (0:00:00.113)       0:00:08.576 ***** 

fatal: [master-1.example.com]: FAILED! => {"changed": false, "msg": "Configuring a value for openshift_hosted_registry_storage_glusterfs_ips and with a glusterfs_registry host group is not allowed.\nSpecifying a glusterfs_registry host group indicates that a new GlusterFS cluster should be configured, whereas\nspecifying openshift_hosted_registry_storage_glusterfs_ips indicates wanting to use a pre-configured GlusterFS cluster for the registry storage."}
fatal: [glusterfs-1.example.com]: FAILED! => {"changed": false, "msg": "Configuring a value for openshift_hosted_registry_storage_glusterfs_ips and with a glusterfs_registry host group is not allowed.\nSpecifying a glusterfs_registry host group indicates that a new GlusterFS cluster should be configured, whereas\nspecifying openshift_hosted_registry_storage_glusterfs_ips indicates wanting to use a pre-configured GlusterFS cluster for the registry storage."}
fatal: [node-1.example.com]: FAILED! => {"changed": false, "msg": "Configuring a value for openshift_hosted_registry_storage_glusterfs_ips and with a glusterfs_registry host group is not allowed.\nSpecifying a glusterfs_registry host group indicates that a new GlusterFS cluster should be configured, whereas\nspecifying openshift_hosted_registry_storage_glusterfs_ips indicates wanting to use a pre-configured GlusterFS cluster for the registry storage."}
fatal: [glusterfs-2.example.com]: FAILED! => {"changed": false, "msg": "Configuring a value for openshift_hosted_registry_storage_glusterfs_ips and with a glusterfs_registry host group is not allowed.\nSpecifying a glusterfs_registry host group indicates that a new GlusterFS cluster should be configured, whereas\nspecifying openshift_hosted_registry_storage_glusterfs_ips indicates wanting to use a pre-configured GlusterFS cluster for the registry storage."}
fatal: [glusterfs-3.example.com]: FAILED! => {"changed": false, "msg": "Configuring a value for openshift_hosted_registry_storage_glusterfs_ips and with a glusterfs_registry host group is not allowed.\nSpecifying a glusterfs_registry host group indicates that a new GlusterFS cluster should be configured, whereas\nspecifying openshift_hosted_registry_storage_glusterfs_ips indicates wanting to use a pre-configured GlusterFS cluster for the registry storage."}

Expected results:
Should pass here

Additional info:
Add a TASK for debug:
# vim ./roles/openshift_sanitize_inventory/tasks/unsupported.yml
...
- name: QE Debug
  debug:
    msg: "openshift_hosted_registry_storage_kind = {{ openshift_hosted_registry_storage_kind }}  openshift_hosted_registry_storage_glusterfs_ips = {{ openshift_hosted_registry_storage_glusterfs_ips }}"
...

Get value:

TASK [openshift_sanitize_inventory : QE Debug] *********************************
Wednesday 24 January 2018  06:38:10 +0000 (0:00:00.070)       0:00:06.521 ***** 
ok: [master-1.example.com] => {
    "msg": "openshift_hosted_registry_storage_kind = glusterfs  openshift_hosted_registry_storage_glusterfs_ips = []"
}
ok: [node-1.example.com] => {
    "msg": "openshift_hosted_registry_storage_kind = glusterfs  openshift_hosted_registry_storage_glusterfs_ips = []"
}
ok: [glusterfs-1.example.com] => {
    "msg": "openshift_hosted_registry_storage_kind = glusterfs  openshift_hosted_registry_storage_glusterfs_ips = []"
}
ok: [glusterfs-2.example.com] => {
    "msg": "openshift_hosted_registry_storage_kind = glusterfs  openshift_hosted_registry_storage_glusterfs_ips = []"
}
ok: [glusterfs-3.example.com] => {
    "msg": "openshift_hosted_registry_storage_kind = glusterfs  openshift_hosted_registry_storage_glusterfs_ips = []"
}

Change '' to [] could fix the issue.

./roles/openshift_sanitize_inventory/tasks/unsupported.yml

-  - openshift_hosted_registry_storage_glusterfs_ips is defined and openshift_hosted_registry_storage_glusterfs_ips != ''
+  - openshift_hosted_registry_storage_glusterfs_ips is defined and openshift_hosted_registry_storage_glusterfs_ips != []
Comment 1 Wenkai Shi 2018-01-24 02:44:12 EST
Block CNS as docker registry back end storage test.
Comment 3 Russell Teague 2018-01-24 13:18:07 EST
Proposed: https://github.com/openshift/openshift-ansible/pull/6857
Comment 5 Wenkai Shi 2018-01-28 23:32:49 EST
Verified with version openshift-ansible-3.9.0-0.31.0.git.0.e0a0ad8.el7, configure check passed.
Comment 8 errata-xmlrpc 2018-03-28 10:22:32 EDT
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-2018:0489

Note You need to log in before you can comment on or make changes to this bug.