harvester: [BUG] Node driver provisioning fails when resource quota configured in project

Harvester 0.3.0 / Rancher 2.6.1

Scenario 1:

  1. Create a new project in Rancher Virtualization Management and configure resource quota for CPU reservation, CPU limit and memory reservation, memory limit.
  2. Create a namespace in the project
  3. Provision a cluster in the namespace using Harvester RKE2 node driver.

Result:

VM fails to be scheduled with error:

8m19s       Warning   FailedCreate            virtualmachineinstance/test321-pool1-e80882ca-mm4ch        
Error creating pod: pods "virt-launcher-test321-pool1-e80882ca-mm4ch-g59vt" is forbidden:
failed quota: default-drbgs: must specify limits.memory

Scenario 2:

  1. Create a new project in Rancher Virtualization Management and configure a resource quota for CPU and memory (requests and limits)
  2. Create a namespace in the project and configure default “Container Resource Limit” with:
CPU limit/reservation: 2000/1000
Memory limit/reservation: 500/256
  1. Provision a cluster in the namespace using Harvester RKE2 node driver and configuring 1GB of memory for the node pool.

Result:

VM fails to be scheduled with error:

FailedCreate | VirtualMachine test123-test123-b814f7b6-f6tf9Error creating virtual machine instance: 
admission webhook "virtualmachineinstances-create-validator.kubevirt.io" denied the request: 
spec.domain.resources.requests.memory '1Gi' is greater than spec.domain.resources.limits.memory '256Mi'

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Comments: 16 (12 by maintainers)

Most upvoted comments

@futuretea, in this scenario, I create a brand new project and set resource quota to 6Gi in the beginning without edit it afterward. I remember also tried changing from 4Gi to 6Gi, the actually quota still set to 4Gi on harvester VM event page. I will try again and file issue if needed

hotplug flag need to be false, tested