Bug 2231839 - Importer pod's priority is not the same as the VM's PriorityClass, and not the same as the DV's PriorityClass
Summary: Importer pod's priority is not the same as the VM's PriorityClass, and not th...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Container Native Virtualization (CNV)
Classification: Red Hat
Component: Storage
Version: 4.14.0
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
: 4.14.0
Assignee: Alexander Wels
QA Contact: Jenia Peimer
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-08-14 11:48 UTC by Jenia Peimer
Modified: 2023-11-08 14:06 UTC (History)
1 user (show)

Fixed In Version: CNV v4.14.0.rhel9-1772
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-11-08 14:06:16 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github kubevirt containerized-data-importer pull 2864 0 None Merged Ensure priority class is assigned to pod populating pvc prime 2023-08-29 12:44:50 UTC
Github kubevirt containerized-data-importer pull 2872 0 None Merged [release-v1.57] Ensure priority class is assigned to pod populating pvc prime 2023-08-29 12:44:52 UTC
Red Hat Issue Tracker CNV-32027 0 None None None 2023-08-14 11:53:22 UTC
Red Hat Product Errata RHSA-2023:6817 0 None None None 2023-11-08 14:06:27 UTC

Description Jenia Peimer 2023-08-14 11:48:57 UTC
Description of problem:
Importer pod's priority is not the same as the VM's PriorityClass, and not the same as the DV's PriorityClass

Version-Release number of selected component (if applicable):
4.14

How reproducible:
Always


Steps to Reproduce:

FLOW 1:

1. Create a PriorityClass

apiVersion: scheduling.k8s.io/v1
kind: PriorityClass
metadata:
  name: vm-priority
value: 1000000


2. Create a VM with 'priorityClassName: vm-priority'

apiVersion: kubevirt.io/v1
kind: VirtualMachine
metadata:
  name: vm-rhel
spec:
  dataVolumeTemplates:
  - metadata:
      name: dv-rhel
    spec:
      storage:
        resources:
          requests:
            storage: 20Gi
        storageClassName: hostpath-csi-basic
      source:
        http:
          url: <rhel-88.qcow2>
  running: true
  template:
    spec:
      domain:
        devices:
          disks:
          - disk:
              bus: virtio
            name: datavolume
        machine:
          type: ""
        resources:
          requests:
            memory: 1.5Gi
      terminationGracePeriodSeconds: 0
      priorityClassName: vm-priority
      volumes:
      - dataVolume:
          name: dv-rhel
        name: datavolume


3. See the priority of the importer pod:

   $ oc get pods importer-prime-25f14350-9bae-4e64-a523-cb631ce1fda5 -ojson | jq .spec.priority
   0
   $ 


FLOW 2:
 
1. Create a PriorityClass for the VM (vm-priority: 2000000) and for the DV (dv-priority: 1000000)

2. Create a VM like in FLOW 1, but also add 'priorityClassName' to the dataVolumeTemplates:

spec:
  dataVolumeTemplates:
  - spec:
      priorityClassName: dv-priority

3. See the priority of the importer pod:

   $ oc get pods importer-prime-d0ca7996-d5f0-4bc1-b2e8-4c6d1a5146dd -ojson | jq .spec.priority
   0
   $ 


Actual results:
The priority of the importer pod is '0'


Expected results:
FLOW 1: The priority of the importer pod should match the 'vm-priority'
FLOW 2: The priority of the importer pod should match the 'dv-priority' and not the 'vm-priority'


Additional info:
Regression

Comment 1 Natalie Gavrielov 2023-08-16 12:27:44 UTC
Hi Jenia, what is the impact of this issue? just priorities being differnet?

Comment 2 Jenia Peimer 2023-08-23 12:25:01 UTC
If there are enough resources, it's not a big issue. Only in case resources are scarce it can be noticeable. 
But it is the loss of functionality that was there

Comment 3 Jenia Peimer 2023-09-07 12:34:40 UTC
Verified on CNV v4.14.0.rhel9-1880

Comment 5 errata-xmlrpc 2023-11-08 14:06:16 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 Virtualization 4.14.0 Images 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-2023:6817


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