-
Bug
-
Resolution: Done-Errata
-
Normal
-
4.14
-
Quality / Stability / Reliability
-
False
-
-
None
-
Moderate
-
No
-
None
-
None
-
None
-
Done
-
Bug Fix
-
-
None
-
None
-
None
-
None
Description of problem:
When trying to delete a ClusterResourceQuota resource, using foreground deletion cascading strategy it's stuck in that state and failing to complete the removal. Once background deletion cascading strategy is used it's immediately removed. Now, given that OpenShift GitOps is using foreground deletion cascading strategy by default, this does expose some challenges when managing ClusterResourceQuota resources using OpenShift GitOps.
Version-Release number of selected component (if applicable):
4.14.0-0.nightly-2023-10-23-223425 but also previous version of OpenShift Container Platform 4 are affected
How reproducible:
Always
Steps to Reproduce:
1. Install OpenShift Container Platform 4
2. Create the ClusterResourceQuota as shown below
$ bat -p /tmp/crq.yaml
apiVersion: quota.openshift.io/v1
kind: ClusterResourceQuota
metadata:
creationTimestamp: null
name: blue
spec:
quota:
hard:
pods: "10"
secrets: "20"
selector:
annotations: null
labels:
matchLabels:
color: nocolor
3. Delete the ClusterResourceQuota using "oc delete --cascade=foreground clusterresourcequota blue"
Actual results:
$ oc delete --cascade=foreground clusterresourcequota blue
clusterresourcequota.quota.openshift.io "blue" deleted
Is stuck and won't finish, the resource looks as shown below.
$ oc get clusterresourcequota blue -o yaml
apiVersion: quota.openshift.io/v1
kind: ClusterResourceQuota
metadata:
annotations:
kubectl.kubernetes.io/last-applied-configuration: |
{"apiVersion":"quota.openshift.io/v1","kind":"ClusterResourceQuota","metadata":{"annotations":{},"creationTimestamp":null,"name":"blue"},"spec":{"quota":{"hard":{"pods":"10","secrets":"20"}},"selector":{"annotations":null,"labels":{"matchLabels":{"color":"nocolor"}}}}}
creationTimestamp: "2023-10-24T07:37:48Z"
deletionGracePeriodSeconds: 0
deletionTimestamp: "2023-10-24T07:59:47Z"
finalizers:
- foregroundDeletion
generation: 2
name: blue
resourceVersion: "60554"
uid: c18dd92c-afeb-47f4-a944-8b55be4037d7
spec:
quota:
hard:
pods: "10"
secrets: "20"
selector:
annotations: null
labels:
matchLabels:
color: nocolor
Expected results:
The ClusterResourceQuota to be deleted using foreground deletion cascading strategy without being stuck as there does not appear to be any OwnerReference that is still around and blocking removal
Additional info:
- links to
-
RHEA-2024:0041
OpenShift Container Platform 4.16.z bug fix update