Bug 1495150

Summary: failed to install OCP when use openshift_logging_es_pvc_dynamic with NFS
Product: OpenShift Container Platform Reporter: Anping Li <anli>
Component: InstallerAssignee: ewolinet
Status: CLOSED ERRATA QA Contact: Anping Li <anli>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 3.7.0CC: anli, aos-bugs, jokerman, mmccomas
Target Milestone: ---   
Target Release: 3.7.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: No Doc Update
Doc Text:
undefined
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-11-28 22:13:02 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 Anping Li 2017-09-25 10:12:15 UTC
Description of problem:
For openshift_hosted_logging&openshift_hosted_metrics will be deprecated. I want to fresh installl OCP and enable logging using none openshift_hosted_logging variables. but the installer failed in role openshift_storage_nfs.


Version-Release number of the following components:
openshift-ansible:master


How reproducible:
always

Steps to Reproduce:
1. set logging deploy variable inventory and use nfs hosts
# Logging
openshift_logging_install_logging=true
openshift_logging_kibana_hostname=kibana.example.com
openshift_logging_kibana_ops_hostname=kibana-ops.example.com
public_master_url=https://example1:8443
openshift_logging_namespace=logging
openshift_logging_fluentd_use_journal=true
openshift_logging_use_mux=true
openshift_logging_use_mux_client=true
openshift_logging_es_pvc_prefix=logging-es
#openshift_logging_es_pvc_size=10G
openshift_logging_purge_logging=true
openshift_logging_es_pvc_dynamic=True
openshift_logging_kibana_memory_limit=1Gi
openshift_logging_kibana_ops_memory_limit=1Gi
openshift_logging_es_memory_limit=1Gi
openshift_logging_es_ops_memory_limit=1Gi


2. install openshift 
 ansible-playbook /root/openshift-ansible/playbooks/byo/config.yml 

Actual results:
TASK [openshift_storage_nfs : Ensure exports directory exists] ****************************************************************************************************************************************************
fatal: [openshift-225.example.com]: FAILED! => {
    "failed": true
}

MSG:

the field 'args' has an invalid value, which appears to include a variable that is undefined. The error was: 'dict object' has no attribute 'storage'

The error appears to have been in '/root/openshift-ansible/roles/openshift_storage_nfs/tasks/main.yml': line 20, column 3, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:


- name: Ensure exports directory exists
  ^ here

    to retry, use: --limit @/root/openshift-ansible/playbooks/byo/config.retry

PLAY RECAP ********************************************************************************************************************************************************************************************************
localhost                  : ok=12   changed=0    unreachable=0    failed=0   
openshift-208.example.com : ok=49   changed=5    unreachable=0    failed=0   
openshift-225.example.com : ok=115  changed=44   unreachable=0    failed=1   



Failure summary:


  1. Hosts:    openshift-225.example.com
     Play:     Configure nfs
     Task:     Ensure exports directory exists
     Message:  the field 'args' has an invalid value, which appears to include a variable that is undefined. The error was: 'dict object' has no attribute 'storage'
               
               The error appears to have been in '/root/openshift-ansible/roles/openshift_storage_nfs/tasks/main.yml': line 20, column 3, but may
               be elsewhere in the file depending on the exact syntax problem.
               
               The offending line appears to be:
               
               
               - name: Ensure exports directory exists
                 ^ here


Expected results:
The install completed, the logging are deployed.

Additional info:

Comment 1 ewolinet 2017-09-26 17:14:52 UTC
Do you have any openshift_logging_storage_* variables set in your inventory too?
I see a different error using the dynamic pvc gen and no pvc size

Comment 3 Anping Li 2017-09-27 00:58:41 UTC
No, I only set openshift_logging_es_ops_pvc_dynamic=True.

Comment 6 Anping Li 2017-10-12 01:37:25 UTC
The fix work well with openshift-ansible v3.7.0-0.148.0.0

Comment 10 errata-xmlrpc 2017-11-28 22:13:02 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/RHSA-2017:3188