Bug 2097263 - Operator ignores managementState Removed
Summary: Operator ignores managementState Removed
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Special Resource Operator
Version: 4.10
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
: 4.10.z
Assignee: Brett Thurber
QA Contact: Udi Kalifon
URL:
Whiteboard:
Depends On: 2083514
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-06-15 10:08 UTC by Pablo Acevedo
Modified: 2022-06-28 11:51 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of: 2083514
Environment:
Last Closed: 2022-06-28 11:51:12 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github openshift special-resource-operator pull 227 0 None open Bug 2097263: Add removeResource function from 4.11 2022-06-15 15:47:36 UTC
Red Hat Product Errata RHBA-2022:5172 0 None None None 2022-06-28 11:51:25 UTC

Description Pablo Acevedo 2022-06-15 10:08:32 UTC
+++ This bug was initially created as a clone of Bug #2083514 +++

Description of problem:
Setting the managementState to Removed on a SpecialResource does not remove the pods

Version-Release number of selected component (if applicable):
master/release-4.11

How reproducible:


Steps to Reproduce:
1. Install SRO from bundle
2. Install simple-kmod
3. patch managementState

Actual results:
Removed state not applied on the running pods


# oc get sr/simple-kmod-second -o json | grep management
# oc patch sr/simple-kmod-second -p '{"spec":{"managementState": "Removed"}}' --type merge -n simple-kmod-second
specialresource.sro.openshift.io/simple-kmod-second patched
# oc get sr/simple-kmod-second -o json | grep management
        "managementState": "Removed",
# oc get sr
NAME                 READY   PROGRESSING   ERRORED
simple-kmod          False   False         True
simple-kmod-second   True    False         False
# oc get pods -n simple-kmod-second
NAME                                                         READY   STATUS    RESTARTS   AGE
simple-kmod-second-driver-container-e383247e62b56585-548rj   1/1     Running   0          7d14h
simple-kmod-second-driver-container-e383247e62b56585-v56l4   1/1     Running   0          7d14h
# oc get pods -n simple-kmod-second
NAME                                                         READY   STATUS    RESTARTS   AGE
simple-kmod-second-driver-container-e383247e62b56585-548rj   1/1     Running   0          7d14h
simple-kmod-second-driver-container-e383247e62b56585-v56l4   1/1     Running   0          7d14h
# oc get pods -n simple-kmod-second
NAME                                                         READY   STATUS    RESTARTS   AGE
simple-kmod-second-driver-container-e383247e62b56585-548rj   1/1     Running   0          7d16h
simple-kmod-second-driver-container-e383247e62b56585-v56l4   1/1     Running   0          7d16h
# 

Expected results:
Pods to be removed

Additional info:

Comment 4 Udi Kalifon 2022-06-24 09:10:34 UTC
Verified with a bundle build from the release-4.10 branch

Comment 6 errata-xmlrpc 2022-06-28 11:51:12 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 (OpenShift Container Platform 4.10.20 bug fix update), 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-2022:5172


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