0

I am getting several issues when trying to install Openshift 3 with ansible. All the errors are differents at each installation but they always rely on a pair of node

Version

openshift-ansible from git repo: openshift-ansible-3.6.173.0.32-1

ansible: 2.3.0.0

Steps To Reproduce

  • Take two nodes and one master
    • node1.my-site.com
    • node2.my-site.com
    • master.my-site.com
  • Follow prerequesites on the openshift documentation.
  • Follow host preparation on the openshift documentation.
  • Write approximatively the same hosts as single master and multiple nodes
  • ansible-playbook playbooks/byo/config.yml

Here is my real playbook:

# to be save in /etc/ansible/hosts.
# coming from https://docs.openshift.org/latest/install_config/install/advanced_install.html#single-master

# Create an OSEv3 group that contains the masters and nodes groups
[OSEv3:children]
masters
nodes

# Set variables common for all OSEv3 hosts
[OSEv3:vars]
# SSH user, this user should allow ssh based auth without requiring a password
ansible_ssh_user=root

# If ansible_ssh_user is not root, ansible_become must be set to true
#ansible_become=true

openshift_deployment_type=origin

openshift_disable_check=memory_availability

# uncomment the following to enable htpasswd authentication; defaults to DenyAllPasswordIdentityProvider
#openshift_master_identity_providers=[{'name': 'htpasswd_auth', 'login': 'true', 'challenge': 'true', 'kind': 'HTPasswdPasswordIdentityProvider', 'filename': '/etc/origin/master/htpasswd'}]

# host group for masters
[masters]
master.my-site.com

# host group for etcd
[etcd]
master.my-site.com

# host group for nodes, includes region info
[nodes]
node1.my-site.com openshift_node_labels="{'region': 'primary', 'zone': 'default'}"
node2.my-site.com openshift_node_labels="{'region': 'primary', 'zone': 'default'}"
infra-node1.my-site.com openshift_node_labels="{'region': 'infra', 'zone': 'default'}"
infra-node2.my-site.com openshift_node_labels="{'region': 'infra', 'zone': 'default'}"

This is basically a copy paste of the one in the docs except that I changed the zones for my nodes.

An important note: Maybe I am doing the thing wrongly: node1.my-site.com resolves the same ip as infra-node1.my-site.com node2.my-site.com resolves the same ip as infra-node2.my-site.com

I don't know if it is the correct way but in the documentation they just talk about 2 nodes so I suspected that it was supposed to resolve same IP.

Observed Results

After approximatively 10 or 20 minutes deployment fail with random errors:

Failure summary:

  1. Host:     node2.my-site.com
     Play:     Verify Requirements
     Task:     openshift_health_check
     Message:  One or more checks failed
     Details:  check "docker_storage":
               Some dependencies are required in order to query docker storage on host:
               Unable to install required packages on this host:
                   python-docker-py
               Failure talking to yum: [Errno 2] No such file or directory: '/var/cache/yum/x86_64/7/epel/gen/primary_db.sqlite'

               check "package_availability":
               Error with yum repository configuration: updates: Check uncompressed DB failed

  2. Host:     infra-node2.my-site.com
     Play:     Verify Requirements
     Task:     openshift_health_check
     Message:  One or more checks failed
     Details:  check "docker_storage":
               Some dependencies are required in order to query docker storage on host:
               Unable to install required packages on this host:
                   python-docker-py
               Failure talking to yum: updates: Check uncompressed DB failed

This one was strange '/var/cache/yum/x86_64/7/epel/gen/primary_db.sqlite' was there verification

Failure summary:

  1. Host:     infra-node1.my-site.com
     Play:     Verify Requirements
     Task:     openshift_health_check
     Message:  One or more checks failed
     Details:  check "package_version":
               MODULE FAILURE

               check "package_availability":
               Error with yum repository configuration: File /var/cache/yum/x86_64/7/epel/metalink.xml is not XML

  2. Host:     node1.my-site.com
     Play:     Verify Requirements
     Task:     openshift_health_check
     Message:  One or more checks failed
     Details:  check "package_version":
               MODULE FAILURE

  3. Host:     infra-node2.my-site.com
     Play:     Verify Requirements
     Task:     openshift_health_check
     Message:  One or more checks failed
     Details:  check "package_version":
               MODULE FAILURE

               check "package_availability":
               Error with yum repository configuration: File /var/cache/yum/x86_64/7/epel/metalink.xml does not exist

  4. Host:     node2.my-site.com
     Play:     Verify Requirements
     Task:     openshift_health_check
     Message:  One or more checks failed
     Details:  check "package_version":
               MODULE FAILURE

               check "package_availability":
               Error with yum repository configuration: File /var/cache/yum/x86_64/7/epel/metalink.xml does not exist

This one file was not an XML I confirm:

<?xml version="1.0" encoding="utf-8"?>
<metalink version="3.0" xmlns="http://www.metalinker.org/" type="dynamic" pubdate="Tue, 12 Sep 2017 20:22:13 GMT" generator="mirrormanager" xmlns:mm0="http://fedorahosted.org/mirrormanager">
  <files>
    <file name="repomd.xml">
      <resources maxconnections="1">
        <url protocol="blablabla">http://blablabla</url>
        ...
        ...
        <url protocol="blablabla">http://blablabla</url>
      </resources>
    </file>
  </files>
</metalink>
x86_64/repodata/repomd.xml</url>                         <==== What?????
        <url protocol="blablabla">http://blablabla</url>
      </resources>
    </file>
  </files>
</metalink>

Third error I do not understand it at all as it is a old.tmp (the repomd.xml was there)

Failure summary:

  1. Host:     infra-node1.my-site.com
     Play:     Disable excluders
     Task:     openshift_excluder : Install docker excluder
     Message:  Failure talking to yum: [Errno 2] No such file or directory: '/var/cache/yum/x86_64/7/centos-openshift-origin/repomd.xml.old.tmp'

Anothere one:

Failure summary:

  1. Host:     node2.my-site.com
     Play:     Verify Requirements
     Task:     openshift_health_check
     Message:  One or more checks failed
     Details:  check "package_availability":
               Error with yum repository configuration: updates: Check uncompressed DB failed

  2. Host:     infra-node2.my-site.com
     Play:     Verify Requirements
     Task:     openshift_health_check
     Message:  One or more checks failed
     Details:  check "package_availability":
               Error with yum repository configuration: updates: Check uncompressed DB failed

And the last one:

Failure summary:

  1. Host:     node1.my-site.com
     Play:     Verify Requirements
     Task:     openshift_health_check
     Message:  One or more checks failed
     Details:  check "package_availability":
               Unexpected error with yum repository: [Errno 2] No such file or directory: '/var/cache/yum/x86_64/7/epel/gen/primary_db.sqlite'

  2. Host:     node2.my-site.com
     Play:     Verify Requirements
     Task:     openshift_health_check
     Message:  One or more checks failed
     Details:  check "package_version":
               MODULE FAILURE

               check "package_availability":
               Unexpected error with yum repository: /builddir/build/BUILD/Python-2.7.5/Objects/stringobject.c:3902: bad argument to internal function

  3. Host:     infra-node2.my-site.com
     Play:     Verify Requirements
     Task:     openshift_health_check
     Message:  One or more checks failed
     Details:  check "package_availability":
               Unexpected error with yum install/update: database disk image is malformed

Additional Information

Provide any additional information which may help us diagnose the issue.

  • OS: centos-release-7-3.1611.el7.centos.x86_64
  • I think I do not do something correct with the hosts file because the concern are almost always the pair node1 infra-node1, node2 infra-node2
  • Master is 15GB of ram and 2 vcpu, nodes are 8 GB and 2 vcpu
  • I am hosted to OVH
  • I killed my platform for security reason
-1

try this link very good explanation. https://keithtenzer.com/2017/08/11/openshift-3-6-fast-track-everything-you-need-nothing-you-dont/

  • 1
    Whilst this may theoretically answer the question, it would be preferable to include the essential parts of the answer here, and provide the link for reference. – Gerald Schneider Sep 13 '17 at 13:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.