ZFS on Proxmox thin-provisoned VMs disks

I’ve been a huge fan of promox since version 1.0 – they later implemented native support of my favorite filesystem ZFS and if you are an early adopter like me your proxmox /etc/pve/storage.cfg file may not have some settings like sparse that the new installations configure by default.

Checking if ZFS VM disk is thin-provisoned

Use the following command to see the zfs properties we care about:

zfs get volblocksize,volsize,refreservation,used  gdata/pve/base-152-disk-0

Expected output


NAME                       PROPERTY        VALUE      SOURCE
gdata/pve/base-152-disk-0  volblocksize    8K         default
gdata/pve/base-152-disk-0  volsize         64G        local
gdata/pve/base-152-disk-0  refreservation  none       local
gdata/pve/base-152-disk-0  used            7.31G      -

The property refreservation=none tells us this disk is thin-provisioned. Meaning ZFS won’t guarantee and account for the VM ‘max disk size’ in the zpool usage metrics. This may be helpful if you want to overprovision a VM disk to say 1TB but rarely use that much and you don’t want zpool list to claim you have 1TB phantom disk usage.

What does a non thin-provisioned ZFS VM disk look like?

The volsize=64G and refreservation=64G would be set on the example above.

Leave a Reply