Uploaded image for project: 'OpenShift Virtualization'
  1. OpenShift Virtualization
  2. CNV-22930

[2148837] Limits are not changed/no options to change the limits while increasing/decreasing the virtual machine resources from GUI

    • Important
    • None

      Description of problem:

      [1] Created a VM with below resources.limit.memory and resources.requests.memory.

      ~~~

      1. oc get vm rhel7-forward-rook -o yaml |yq -y '.spec.template.spec.domain.resources'
        limits:
        memory: 5Gi
        requests:
        memory: 4Gi
        ~~~

      The namespace has got Max Limit/Request Ratio for memory set to 2.

      ~~~

      1. oc describe limits
        Name: resource-limits
        Namespace: nijin-cnv
        Type Resource Min Max Default Request Default Limit Max Limit/Request Ratio
            • -------- — — --------------- ------------- -----------------------
              Container cpu - 2 2 2 -
              Container memory - 8Gi 4Gi 4Gi 2 <<<
              ~~~

      [2] Increased the VM memory to 5 Gi from the web UI.

      ~~~
      Click on VM => Details => Edit CPU | Memory
      ~~~

      This only increased the requests and not the limits.

      ~~~

      1. oc get vm rhel7-forward-rook -o yaml|yq -y '.spec.template.spec.domain.resources'
        limits:
        memory: 5Gi
        requests:
        memory: 5Gi
        ~~~

      VM will start since the ratio is 1 less than maxLimitRequestRatio.

      [3] Decreased the VM memory to 2 Gi from web UI and now, the VM startup fails with the error below because the ratio is more than 2:

      ~~~
      Click on VM => Details => Edit CPU | Memory
      ~~~

      ~~~
      5s Warning FailedCreate virtualmachineinstance/rhel7-forward-rook (combined from similar events): Error creating pod: pods "virt-launcher-rhel7-forward-rook-f78gg" is forbidden: memory max limit to request ratio per Container is 2, but provided ratio is 2.342071
      ~~~

      In [2] and [3], there is no option to mention the limits. Also, it doesn't increase the limits automatically in proportion to the increase in requests.

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

      OpenShift Virtualization 4.11.0

      How reproducible:

      100%

      Steps to Reproduce:

      Please refer above.

      Actual results:

      Limits are not changed/no options to change the limits while increasing/decreasing the virtual machine resources from GUI

      Expected results:

      The customer is expecting to decrease/increase the limits in proportion to the increase/decrease of the requests.

      Additional info:

              phbailey@redhat.com Phillip Rhodes
              rhn-support-nashok Nijin Ashok
              Kedar Bidarkar Kedar Bidarkar
              Votes:
              0 Vote for this issue
              Watchers:
              9 Start watching this issue

                Created:
                Updated:
                Resolved: