Bug 1619388 - [CRS]Independent mode of deployment requires python-docker on RHGS nodes
Summary: [CRS]Independent mode of deployment requires python-docker on RHGS nodes
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Gluster Storage
Classification: Red Hat Storage
Component: cns-ansible
Version: cns-3.10
Hardware: x86_64
OS: Linux
unspecified
medium
Target Milestone: ---
: ---
Assignee: Jose A. Rivera
QA Contact: Prasanth
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-08-20 17:12 UTC by Mugdha Soni
Modified: 2020-02-24 06:44 UTC (History)
16 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-03-21 19:37:29 UTC
Embargoed:


Attachments (Terms of Use)
inventory file used for CRS. (4.63 KB, text/plain)
2018-08-20 17:12 UTC, Mugdha Soni
no flags Details
ansible log file captured on the master (56.62 KB, application/octet-stream)
2018-08-21 03:01 UTC, SATHEESARAN
no flags Details
enterprise error (123.18 KB, text/plain)
2018-08-24 06:15 UTC, Mugdha Soni
no flags Details
inventory file with glusterfs removed from OSEv3:children (4.85 KB, application/octet-stream)
2018-08-24 17:58 UTC, SATHEESARAN
no flags Details
ansible.log file corresponding to execution with inventory file without gluster in OSEv3:children (75.29 KB, application/octet-stream)
2018-08-24 18:00 UTC, SATHEESARAN
no flags Details
Change g_all_hosts patch (1014 bytes, patch)
2018-08-27 19:39 UTC, Jose A. Rivera
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1623923 0 urgent CLOSED Ship python-docker and dependencies to RHGS repo for OCS independent mode deployment 2021-02-22 00:41:40 UTC

Internal Links: 1623923

Description Mugdha Soni 2018-08-20 17:12:46 UTC
Created attachment 1477315 [details]
inventory file used for CRS.

Description of problem:
-------------------------------
The independent mode of deployment threw error while running the prerequisite ansible playbook. It is searching for the python-docker package on the gluster nodes. The gluster nodes should neither have nor look for the ocp related packages because gluster nodes are out of CNS setup.

Version-Release number of selected component:
--------------------------------
oc v3.10.14
glusterfs-3.12.2-16

How reproducible:
------------------------------
Everytime

Steps to Reproduce:
-------------------------------
1.Install Red Hat Gluster Storage Server on RHEL.
2.Configure port access,kernel module and enable sshd,gluster-blockd and glusterd services.
3.Edit the CRS inventory file and run the ansible playbook for the prerequisites.

Actual results:
------------------------------
It threw an error looking for python docker package in gluster nodes.


Expected results:
-----------------------------
Python-docker package is not required in gluster nodes.

Comment 3 SATHEESARAN 2018-08-21 03:01:46 UTC
Created attachment 1477395 [details]
ansible log file captured on the master

Comment 14 Mugdha Soni 2018-08-24 06:14:16 UTC
## In reply to comment 12 by Jose A.Rivera.

Jose , i tried deployment with suggested changes but it gave a new error.
I have attached the ansible logs and setup details where i faced this issue while deploying metrics,registry and logging.

Comment 15 Mugdha Soni 2018-08-24 06:15:10 UTC
Created attachment 1478400 [details]
enterprise error

Comment 16 SATHEESARAN 2018-08-24 06:23:22 UTC
I have also seen the similar problem with my setup.

Here is the snip of the console log.

<snip>

TASK [Run variable sanity checks] *********************************************************************************************************************************************************************************
fatal: [dhcp47-157.lab.eng.blr.redhat.com]: FAILED! => {"failed": true, "msg": "last_checked_host: dhcp47-22.lab.eng.blr.redhat.com, last_checked_var: openshift_deployment_type;openshift_deployment_type must be 
defined and one of origin, openshift-enterprise"}
        to retry, use: --limit @/usr/share/ansible/openshift-ansible/playbooks/prerequisites.retry

PLAY RECAP ********************************************************************************************************************************************************************************************************
dhcp46-205.lab.eng.blr.redhat.com : ok=14   changed=0    unreachable=0    failed=1   
dhcp46-224.lab.eng.blr.redhat.com : ok=31   changed=6    unreachable=0    failed=0
dhcp46-51.lab.eng.blr.redhat.com : ok=31   changed=6    unreachable=0    failed=0
dhcp47-145.lab.eng.blr.redhat.com : ok=31   changed=6    unreachable=0    failed=0
dhcp47-157.lab.eng.blr.redhat.com : ok=49   changed=6    unreachable=0    failed=1   
dhcp47-2.lab.eng.blr.redhat.com : ok=14   changed=0    unreachable=0    failed=1   
dhcp47-22.lab.eng.blr.redhat.com : ok=15   changed=0    unreachable=0    failed=1   
localhost                  : ok=14   changed=0    unreachable=0    failed=0

</snip>

Comment 17 Jose A. Rivera 2018-08-24 15:59:14 UTC
I'm going to guess that your inventory file has changed, since the following machines were not listed in the one you posted at the beginning:

[dhcp46-221.lab.eng.blr.redhat.com]
[dhcp46-94.lab.eng.blr.redhat.com]
[dhcp46-106.lab.eng.blr.redhat.com]

In any case, it seems I was wrong! Please put back the glusterfs group names under [OSEv3:children]. Try manually installing python-docker on all the CRS nodes and see if that fixes the problem. We'll figure out what the right fix is afterwards.

Comment 18 SATHEESARAN 2018-08-24 17:58:52 UTC
Created attachment 1478592 [details]
inventory file with glusterfs removed from OSEv3:children

Comment 19 SATHEESARAN 2018-08-24 18:00:26 UTC
Created attachment 1478593 [details]
ansible.log file corresponding to execution with inventory file without gluster in OSEv3:children

Comment 21 Jose A. Rivera 2018-08-27 19:39:35 UTC
Created attachment 1479042 [details]
Change g_all_hosts patch

I'm cooking up a potential fix, but I don't currently have an environment where I can test an external GlusterFS cluster that's not on OCP nodes. If someone (Mugdha?) is willing to experiment for me, would you be willing to apply the following patch (with "patch" or manually) to the files in /usr/share/ansible/openshift-ansible? If you download the patch to the home directory, you can apply it with the following:

patch -p1 -d /usr/share/ansible/openshift-ansible/ <~/groups.patch 

To remove it (in case it breaks everything), just do:

patch -p1 -d /usr/share/ansible/openshift-ansible/ -R <~/groups.patch

Comment 22 Jose A. Rivera 2018-08-27 19:40:49 UTC
Oops, shouldn't have checked the patch box. :) URL to the raw patch:

https://bugzilla.redhat.com/attachment.cgi?id=1479042&action=diff&context=patch&collapsed=&headers=1&format=raw

Comment 26 SATHEESARAN 2018-08-29 07:40:26 UTC
On consolidation from comment24 and comment25, there are 5 packages that are required to be made available with RHGS nodes to support independent mode of OCS installation:

 - python-docker ( ose-3.10 repo )
 - python-docker-pycreds ( extras repo )
 - python-websocket-client ( extras repo )
 - python2-urllib3 ( ose-3.10 repo )
 - python2-pysocks ( ose-3.10 repo )

Comment 32 Jose A. Rivera 2018-08-31 16:28:24 UTC
This PR may help solve the issue: https://github.com/openshift/openshift-ansible/pull/9847

Comment 33 Jose A. Rivera 2018-09-06 17:15:59 UTC
PR merged. Backport PR:https://github.com/openshift/openshift-ansible/pull/9934

Comment 34 Jose A. Rivera 2018-09-07 19:11:41 UTC
Backport PR merged.

Comment 35 SATHEESARAN 2018-09-10 06:44:49 UTC
(In reply to Jose A. Rivera from comment #21)
> Created attachment 1479042 [details]
> Change g_all_hosts patch
> 
> I'm cooking up a potential fix, but I don't currently have an environment
> where I can test an external GlusterFS cluster that's not on OCP nodes. If
> someone (Mugdha?) is willing to experiment for me, would you be willing to
> apply the following patch (with "patch" or manually) to the files in
> /usr/share/ansible/openshift-ansible? If you download the patch to the home
> directory, you can apply it with the following:
> 
> patch -p1 -d /usr/share/ansible/openshift-ansible/ <~/groups.patch 
> 
> To remove it (in case it breaks everything), just do:
> 
> patch -p1 -d /usr/share/ansible/openshift-ansible/ -R <~/groups.patch

Missed to update the bug. I have tested with this patch and the error is gone


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