Bug 2083514 - 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.11
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
: 4.11.0
Assignee: Pablo Acevedo
QA Contact: Constantin Vultur
URL:
Whiteboard:
Depends On:
Blocks: 2094423 2097263
TreeView+ depends on / blocked
 
Reported: 2022-05-10 09:40 UTC by Constantin Vultur
Modified: 2022-08-10 11:11 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 2094423 2097263 (view as bug list)
Environment:
Last Closed: 2022-08-10 11:11:01 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github openshift special-resource-operator pull 211 0 None open Bug 2083514: Add resource removal capabilities 2022-05-19 19:33:30 UTC
Red Hat Product Errata RHSA-2022:5069 0 None None None 2022-08-10 11:11:19 UTC

Description Constantin Vultur 2022-05-10 09:40:23 UTC
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 6 errata-xmlrpc 2022-08-10 11:11:01 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 (Important: OpenShift Container Platform 4.11.0 bug fix and security 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/RHSA-2022:5069


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