Bug 1880913 - [DeScheduler] - change loglevel from Info to Error when priority class given in the descheduler params is not present in the cluster
Summary: [DeScheduler] - change loglevel from Info to Error when priority class given ...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: kube-scheduler
Version: 4.6
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: ---
: 4.7.0
Assignee: Jan Chaloupka
QA Contact: RamaKasturi
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-09-21 06:33 UTC by RamaKasturi
Modified: 2021-02-24 15:20 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: No Doc Update
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-02-24 15:18:56 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github kubernetes-sigs descheduler pull 409 0 None closed Change klog info messages after a strategy is exited into error messages 2020-10-27 12:05:06 UTC
Github openshift descheduler pull 43 0 None closed bug 1880913: Sync with upstream 2020-10-27 12:05:06 UTC
Red Hat Product Errata RHSA-2020:5633 0 None None None 2021-02-24 15:20:57 UTC

Description RamaKasturi 2020-09-21 06:33:21 UTC
Description of problem:
When user tries to specifies a priorityclass in the descheduler params which is not present descheduler gives Info instead of Error as below

Version-Release number of selected component (if applicable):
4.6.0-0.nightly-2020-09-17-195238

How Reproducible:
Always

Steps to Reproduce:
1. Install latest 4.6 cluster
2. Add strategies as below to descheduler
- name: "RemoveDuplicates"
   params:
   - name: "excludeOwnerKinds"
     value: " DeploymentConfig"
   - name: "thresholdPriorityClassName"
      value: "priorityclass1"
3. Now check the cluster pod logs

Actual Results:
cluster pod log shows below messages and the message gets logs as Info
I0918 07:19:46.763498       1 duplicates.go:66] "Failed to get threshold priority from strategy's params" err="priorityclasses.scheduling.k8s.io \"priorityclass1\" not found"

Expected Results:
Message about priorityclass not being found should be logged as Error and not Info.

Comment 1 Jan Chaloupka 2020-09-22 10:36:06 UTC
Upstream PR: https://github.com/kubernetes-sigs/descheduler/pull/409

Comment 2 Jan Chaloupka 2020-10-01 15:11:56 UTC
Fix is available and merged. The code just needs to be rebased with the latest descheduler release.

Comment 5 RamaKasturi 2020-10-27 12:22:26 UTC
Verified with the payload below and i see that Info message has been changed to Error.

[knarra@knarra openshift-client-linux-4.7.0-0.nightly-2020-10-27-051128]$ ./oc get csv
NAME                                                   DISPLAY                     VERSION                 REPLACES   PHASE
clusterkubedescheduleroperator.4.7.0-202010261508.p0   Kube Descheduler Operator   4.7.0-202010261508.p0              Succeeded
[knarra@knarra openshift-client-linux-4.7.0-0.nightly-2020-10-27-051128]$ ./oc version
Client Version: 4.7.0-0.nightly-2020-10-27-051128
Server Version: 4.7.0-0.nightly-2020-10-27-051128
Kubernetes Version: v1.19.0+e67f5dc

When a priorityclass which does not exist is mentioned cluster logs throws error as below.

I1027 12:19:03.924834       1 node.go:46] "Node lister returned empty list, now fetch directly"
E1027 12:19:04.017529       1 duplicates.go:70] "Failed to get threshold priority from strategy's params" err="priorityclasses.scheduling.k8s.io \"priorityclass1\" not found"

Based on the above moving bug to verified state.

Comment 8 errata-xmlrpc 2021-02-24 15:18:56 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.7.0 security, bug fix, and enhancement 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:5633


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