Bug 1891527 - openshift-object-counts quota is not dynamically updating as the resource is deleted.
Summary: openshift-object-counts quota is not dynamically updating as the resource is ...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: kube-controller-manager
Version: 4.5
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: 4.5.z
Assignee: Lukasz Szaszkiewicz
QA Contact: RamaKasturi
URL:
Whiteboard:
Depends On: 1891518
Blocks: 1891532
TreeView+ depends on / blocked
 
Reported: 2020-10-26 14:39 UTC by Lukasz Szaszkiewicz
Modified: 2021-08-25 06:15 UTC (History)
11 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of: 1891518
: 1891532 (view as bug list)
Environment:
Last Closed: 2020-12-15 20:28:44 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github openshift cluster-policy-controller pull 47 0 None closed [release-4.5] Bug 1891527: openshift-object-counts quota is not dynamically updating as the resource is deleted 2021-01-12 07:56:56 UTC
Red Hat Product Errata RHSA-2020:5359 0 None None None 2020-12-15 20:29:12 UTC

Comment 1 Lukasz Szaszkiewicz 2020-11-16 09:47:43 UTC
I'm in the process of backporting the fix to the earlier version.

Comment 2 RamaKasturi 2020-12-03 07:07:12 UTC
Verified bug with payload below and i see that the fix works.

[knarra@knarra openshift-client-linux-4.5.0-0.nightly-2020-12-03-035613]$ ./oc get clusterversion
NAME      VERSION                                           AVAILABLE   PROGRESSING   SINCE   STATUS
version   4.5.0-0.ci.test-2020-12-03-054047-ci-ln-jmk8422   True        False         46m     Cluster version is 4.5.0-0.ci.test-2020-12-03-054047-ci-ln-jmk8422

Test Results:
================
[knarra@knarra openshift-client-linux-4.5.0-0.nightly-2020-12-03-035613]$ ./oc new-project knarra
Now using project "knarra" on server "https://api.ci-ln-jmk8422-f76d1.origin-ci-int-gce.dev.openshift.com:6443".

You can add applications to this project with the 'new-app' command. For example, try:

    oc new-app ruby~https://github.com/sclorg/ruby-ex.git

to build a new example application in Ruby. Or use kubectl to deploy a simple Kubernetes application:

    kubectl create deployment hello-node --image=gcr.io/hello-minikube-zero-install/hello-node

[knarra@knarra openshift-client-linux-4.5.0-0.nightly-2020-12-03-035613]$ ./oc create quota test1 --hard=openshift.io/imagestreams=10
resourcequota/test1 created
[knarra@knarra openshift-client-linux-4.5.0-0.nightly-2020-12-03-035613]$ ./oc describe quota test1
Name:                      test1
Namespace:                 knarra
Resource                   Used  Hard
--------                   ----  ----
openshift.io/imagestreams  0     10
[knarra@knarra openshift-client-linux-4.5.0-0.nightly-2020-12-03-035613]$ ./oc new-app httpd-example
--> Deploying template "openshift/httpd-example" to project knarra

     Apache HTTP Server
     ---------
     An example Apache HTTP Server (httpd) application that serves static content. For more information about using this template, including OpenShift considerations, see https://github.com/sclorg/httpd-ex/blob/master/README.md.

     The following service(s) have been created in your project: httpd-example.
     
     For more information about using this template, including OpenShift considerations, see https://github.com/sclorg/httpd-ex/blob/master/README.md.

     * With parameters:
        * Name=httpd-example
        * Namespace=openshift
        * Memory Limit=512Mi
        * Git Repository URL=https://github.com/sclorg/httpd-ex.git
        * Git Reference=
        * Context Directory=
        * Application Hostname=
        * GitHub Webhook Secret=dvY4uL1oBCxWu03yVtlst2wbdTctvaQYuN5dCGB1 # generated
        * Generic Webhook Secret=IEyOqt0uxLQD56JxULYFANvLyqJCfPKlMkNS0vlV # generated

--> Creating resources ...
    service "httpd-example" created
    route.route.openshift.io "httpd-example" created
    imagestream.image.openshift.io "httpd-example" created
    buildconfig.build.openshift.io "httpd-example" created
    deploymentconfig.apps.openshift.io "httpd-example" created
--> Success
    Access your application via route 'httpd-example-knarra.apps.ci-ln-jmk8422-f76d1.origin-ci-int-gce.dev.openshift.com' 
    Build scheduled, use 'oc logs -f bc/httpd-example' to track its progress.
    Run 'oc status' to view your app.
[knarra@knarra openshift-client-linux-4.5.0-0.nightly-2020-12-03-035613]$ ./oc get is
NAME            IMAGE REPOSITORY                                                        TAGS   UPDATED
httpd-example   image-registry.openshift-image-registry.svc:5000/knarra/httpd-example          
[knarra@knarra openshift-client-linux-4.5.0-0.nightly-2020-12-03-035613]$ ./oc describe quota test1
Name:                      test1
Namespace:                 knarra
Resource                   Used  Hard
--------                   ----  ----
openshift.io/imagestreams  1     10
[knarra@knarra openshift-client-linux-4.5.0-0.nightly-2020-12-03-035613]$ ./oc delete all --all
pod "httpd-example-1-8sqkn" deleted
pod "httpd-example-1-build" deleted
pod "httpd-example-1-deploy" deleted
replicationcontroller "httpd-example-1" deleted
service "httpd-example" deleted
deploymentconfig.apps.openshift.io "httpd-example" deleted
buildconfig.build.openshift.io "httpd-example" deleted
imagestream.image.openshift.io "httpd-example" deleted
route.route.openshift.io "httpd-example" deleted
[knarra@knarra openshift-client-linux-4.5.0-0.nightly-2020-12-03-035613]$ ./oc get is
No resources found in knarra namespace.
[knarra@knarra openshift-client-linux-4.5.0-0.nightly-2020-12-03-035613]$ ./oc describe quota test1
Name:                      test1
Namespace:                 knarra
Resource                   Used  Hard
--------                   ----  ----
openshift.io/imagestreams  0     10

Comment 3 Lukasz Szaszkiewicz 2020-12-03 13:23:14 UTC
@Rama, thanks, could you movie it to VERIFIED state ?

Comment 4 RamaKasturi 2020-12-03 13:33:54 UTC
(In reply to Lukasz Szaszkiewicz from comment #3)
> @Rama, thanks, could you movie it to VERIFIED state ?

Hey, once the bug is moved to ON_QA and nightly payload contains the fix, bug is moved automatically to VERIFIED state, if not i will move it to VERIFIED once the bug is ON_QA. Thanks !!

Comment 8 errata-xmlrpc 2020-12-15 20:28:44 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 (Moderate: OpenShift Container Platform 4.5.23 security and 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/RHSA-2020:5359


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