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

Available space is less than virtual image size while creating VMs from templates on Portworx filesystem volumes

XMLWordPrintable

    • 1
    • False
    • Hide

      None

      Show
      None
    • False
    • None
    • CNV-34312 - Storage Partner Integration
    • ---
    • ---
    • Storage Core Sprint 256, Storage Core Sprint 257, Storage Core Sprint 258
    • Important
    • No

      Description of problem:

      For Portworx filesystem volumes, the overhead appears to be higher than the default 5.5% overhead in CDI. Portworx is using ext4 with default reserved blocks of 5%. So the total overhead looks to be around 7.5%. Since the cluster was having default overhead, the boot source images was only extended to 5.5%.

       

      # oc get pvc rhel9-6c486c3e5f8c -n openshift-virtualization-os-images -o yaml |yq '.spec.resources'
      requests:
        storage: "34087042032"

       

      When a new VM was created from this template image (both with csi-clone and host assisted clone), the available size was always less than that of the virtual image size of the disk:

       

      Total Available = 29511680 + 1511424 = 31023104 Ki = 29.58 Gi
      sh-5.1$ df  /var/run/kubevirt-private/vmi-disks/rootdisk/disk.img
      Filesystem                                         1K-blocks    Used Available Use% Mounted on
      172.30.29.72:/var/lib/osd/pxns/1064291030995076819  32716800 1511424  29511680   5% /run/kubevirt-private/vmi-disks/rootdisk
      
      sh-5.1$ qemu-img info /var/run/kubevirt-private/vmi-disks/rootdisk/disk.img
      image: /var/run/kubevirt-private/vmi-disks/rootdisk/disk.img
      file format: raw
      virtual size: 30 GiB (32212254720 bytes)
      disk size: 1.47 GiB
      Child node '/file':
          filename: /var/run/kubevirt-private/vmi-disks/rootdisk/disk.img
          protocol type: file
          file length: 30 GiB (32212254720 bytes)     <==
          disk size: 1.47 GiB

       If I fill the filesystem from the VM, the VM goes into paused state when it don't have enough space to allocate in the backing filesystem.  

      sh-5.1$ du  /var/run/kubevirt-private/vmi-disks/rootdisk/disk.img
      31022448    /var/run/kubevirt-private/vmi-disks/rootdisk/disk.img
      
      sh-5.1$ virsh -r list
      Authorization not available. Check if polkit service is running or see debug message for more information.
       Id   Name                                 State
      ---------------------------------------------------
       1    nijin-cnv_rhel9-lime-chimpanzee-65   paused

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

      OpenShift Virtualization   4.15.0

      How reproducible:

      100%

      Steps to Reproduce:

      1. Use Portworx filesystem volume as default storage class and populate the boot images of the default templates on this storage class.
      2. Create a VM from any of the default template and check the available space from the virt-launcher pod. It will be less than the virtual image size of the image.
      

      Actual results:

      Available space is less than virtual image size while creating VMs from templates on Portworx filesystem volumes. When the image grows, the VM may end up in paused state when the backing filesystem don't have enough space. 

      Expected results:

      Validate and provide error message if the target filesystem available space is less than virtual size of the image so that user can increase the overhead.

      Additional info:

       

              akalenyu Alex Kalenyuk
              rhn-support-nashok Nijin Ashok
              Jenia Peimer Jenia Peimer
              Votes:
              0 Vote for this issue
              Watchers:
              10 Start watching this issue

                Created:
                Updated:
                Resolved: