Bug 1329165

Summary: [quick install] Throw exception when choosing first master as storage host by default
Product: OpenShift Container Platform Reporter: Gan Huang <ghuang>
Component: InstallerAssignee: Samuel Munilla <smunilla>
Status: CLOSED ERRATA QA Contact: Ma xiaoqiang <xiama>
Severity: medium Docs Contact:
Priority: medium    
Version: 3.2.0CC: aos-bugs, bleanhar, jokerman, mmccomas, tdawson, xtian
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-05-12 16:40:47 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:

Description Gan Huang 2016-04-21 10:10:04 UTC
Description of problem:
When choosing first master as storage host to install a no-ha env(it's the default selection in quick-installer), quick-installer will throw exception.

Version-Release number of selected component (if applicable):
atomic-openshift-utils-3.0.82-1.git.0.5e5b4bf.el7.noarch

How reproducible:
Always

Steps to Reproduce:
1.Set up a all-in-one env by quick-installer
2.Press "Enter"(that means choosing default selection) in following step:

Setting up High Availability Masters requires a storage host. Please provide a
host that will be configured as a Registry Storage.

Note: Containerized storage hosts are not currently supported.

Enter hostname or IP address [172.16.x.x]: 



Actual results:
Do the above facts look correct? [y/N]: y
Traceback (most recent call last):
  File "/usr/bin/atomic-openshift-installer", line 9, in <module>
    load_entry_point('ooinstall==3.0.0', 'console_scripts', 'oo-install')()
  File "/usr/lib/python2.7/site-packages/click/core.py", line 664, in __call__
    return self.main(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/click/core.py", line 644, in main
    rv = self.invoke(ctx)
  File "/usr/lib/python2.7/site-packages/click/core.py", line 991, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/usr/lib/python2.7/site-packages/click/core.py", line 837, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/usr/lib/python2.7/site-packages/click/core.py", line 464, in invoke
    return callback(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/ooinstall/cli_installer.py", line 905, in install
    oo_cfg.save_to_disk()
  File "/usr/lib/python2.7/site-packages/ooinstall/oo_config.py", line 236, in save_to_disk
    out_file.write(self.yaml())
  File "/usr/lib/python2.7/site-packages/ooinstall/oo_config.py", line 256, in yaml
    return yaml.safe_dump(self.persist_settings(), default_flow_style=False)
  File "/usr/lib64/python2.7/site-packages/yaml/__init__.py", line 218, in safe_dump
    return dump_all([data], stream, Dumper=SafeDumper, **kwds)
  File "/usr/lib64/python2.7/site-packages/yaml/__init__.py", line 190, in dump_all
    dumper.represent(data)
  File "/usr/lib64/python2.7/site-packages/yaml/representer.py", line 28, in represent
    node = self.represent_data(data)
  File "/usr/lib64/python2.7/site-packages/yaml/representer.py", line 57, in represent_data
    node = self.yaml_representers[data_types[0]](self, data)
  File "/usr/lib64/python2.7/site-packages/yaml/representer.py", line 223, in represent_dict
    return self.represent_mapping(u'tag:yaml.org,2002:map', data)
  File "/usr/lib64/python2.7/site-packages/yaml/representer.py", line 123, in represent_mapping
    node_value = self.represent_data(item_value)
  File "/usr/lib64/python2.7/site-packages/yaml/representer.py", line 57, in represent_data
    node = self.yaml_representers[data_types[0]](self, data)
  File "/usr/lib64/python2.7/site-packages/yaml/representer.py", line 215, in represent_list
    return self.represent_sequence(u'tag:yaml.org,2002:seq', data)
  File "/usr/lib64/python2.7/site-packages/yaml/representer.py", line 101, in represent_sequence
    node_item = self.represent_data(item)
  File "/usr/lib64/python2.7/site-packages/yaml/representer.py", line 57, in represent_data
    node = self.yaml_representers[data_types[0]](self, data)
  File "/usr/lib64/python2.7/site-packages/yaml/representer.py", line 223, in represent_dict
    return self.represent_mapping(u'tag:yaml.org,2002:map', data)
  File "/usr/lib64/python2.7/site-packages/yaml/representer.py", line 123, in represent_mapping
    node_value = self.represent_data(item_value)
  File "/usr/lib64/python2.7/site-packages/yaml/representer.py", line 67, in represent_data
    node = self.yaml_representers[None](self, data)
  File "/usr/lib64/python2.7/site-packages/yaml/representer.py", line 247, in represent_undefined
    raise RepresenterError("cannot represent an object: %s" % data)


Expected results:
No exceptions.

Additional info:
Not meet such issue in HA installation.

Comment 2 Samuel Munilla 2016-04-21 18:10:31 UTC
https://github.com/openshift/openshift-ansible/pull/1787/files should handle this error.

Comment 3 Troy Dawson 2016-04-22 20:34:45 UTC
Should be fixed in openshift-ansible-3.0.84-1.git.0.04b5245.el7

Comment 4 Gan Huang 2016-04-25 05:51:07 UTC
Fixed in atomic-openshift-utils-3.0.84-1.git.0.04b5245.el7.noarch

Move it to verified.

Comment 6 errata-xmlrpc 2016-05-12 16:40:47 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-2016:1065