Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1608269 - Uninstall the olm failed via the openshift-ansible
Uninstall the olm failed via the openshift-ansible
Status: CLOSED ERRATA
Product: OpenShift Container Platform
Classification: Red Hat
Component: Service Broker (Show other bugs)
3.11.0
Unspecified Unspecified
medium Severity medium
: ---
: 3.11.0
Assigned To: Evan Cordell
Jian Zhang
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2018-07-25 04:45 EDT by Jian Zhang
Modified: 2018-10-11 03:22 EDT (History)
7 users (show)

See Also:
Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2018-10-11 03:22:06 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:2652 None None None 2018-10-11 03:22 EDT

  None (edit)
Description Jian Zhang 2018-07-25 04:45:07 EDT
Description of problem:
Got below errors when uninstalling the olm via ansible.
"Error from server (NotFound): the server could not find the requested resource (delete catalogsource-v1s.app.coreos.com tectonic-ocs)\n"

Version-Release number of selected component (if applicable):
openshift-ansible master branch
OCP 3.11
oc v3.11.0-0.9.0

How reproducible:
always

Steps to Reproduce:
1, build an OCP 3.11 with the olm enabled.
2. git clone the opnshift-ansible, checkout the master branch.

3. Enable the below variables in your inventory file, and then run "ansible-playbook -i qe-inventory-host-file playbooks/olm/config.yml" command.

operator_lifecycle_manager_remove=true
operator_lifecycle_manager_install=false


Actual results:
TASK [olm : Remove tectonic-ocs CatalogSource-v1 manifest] ********************************************************************************************************************************************************
Wednesday 25 July 2018  15:52:50 +0800 (0:00:02.068)       0:01:09.365 ******** 
...
fatal: [qe-jiazha-311master-etcd-1.0724-q2x.qe.rhcloud.com]: FAILED! => {"changed": false, "msg": {"cmd": "/usr/bin/oc delete CatalogSource-v1 tectonic-ocs -n operator-lifecycle-manager", "results": {}, "returncode": 1, "stderr": "Error from server (NotFound): the server could not find the requested resource (delete catalogsource-v1s.app.coreos.com tectonic-ocs)\n", "stdout": ""}}

Before the uninstalling, the "tectonic-ocs" did exist, I think we should put this removing before the CRD removing.

Expected results:
The olm can be uninstalled success via ansible.

Additional info:
Comment 1 Jian Zhang 2018-07-25 04:52:08 EDT
I submit a PR https://github.com/openshift/openshift-ansible/pull/9334 to fix this issue, looking for your comments.
Comment 3 Vadim Rutkovsky 2018-08-10 03:54:57 EDT
Fix is available in openshift-ansible-3.11.0-0.13.0
Comment 5 Jian Zhang 2018-08-15 03:37:26 EDT
Remove the Depends on 1615191 since I can install the OLM separately.

Set below variable in the inventory file:
operator_lifecycle_manager_remove=true
operator_lifecycle_manager_install=false

And then, run:
[jzhang@localhost openshift-ansible]$ ansible-playbook -i qe-inventory-host-file playbooks/olm/config.yml 

Success, but the namespace was NOT deleted. Verify failed.

[root@qe-jiazha-round3master-etcd-1 ~]# oc get all -n operator-lifecycle-manager
No resources found.
[root@qe-jiazha-round3master-etcd-1 ~]# oc get ns | grep operator
operator-lifecycle-manager          Active    3h


Verify failed and I file a PR(https://github.com/openshift/openshift-ansible/pull/9599) to fix this. Please have a review!
Comment 6 Vadim Rutkovsky 2018-08-15 05:52:06 EDT
Thanks for the PR, merged in master
Comment 7 Vadim Rutkovsky 2018-08-15 08:03:58 EDT
Fix is available in openshift-ansible-3.11.0-0.16.0
Comment 8 Jian Zhang 2018-08-15 23:10:23 EDT
I used the openshift-ansible-3.11.0-0.16.0 branch to test it, LGTM, verify it.
Comment 10 errata-xmlrpc 2018-10-11 03:22:06 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:2652

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