I have a ZFS volume "tank/kvm/webhosting", exposed through iSCSI (using tgt
) to KVM guest.
<disk type='block' device='disk'>
<driver name='qemu' type='raw' cache='none' io='native' discard='unmap'/>
<source dev='/dev/disk/by-path/ip-10.1.200.2:3260-iscsi-iqn.2016-05.bla:webhosting-lun-1'/>
<target dev='sda' bus='scsi'/>
<address type='drive' controller='0' bus='0' target='0' unit='0'/>
</disk>
How to enable space reclamation on ZFS? From guests side it's working (fstrim -v /
), but iSCSI/ZFS host shows errors in log:
tgtd[324]: tgtd: bs_rdwr_request(227) Failed to punch hole for WRITE_SAME command
tgtd[324]: tgtd: bs_rdwr_request(370) io error 0x18086b0 93 -1 0 2674021892096, No such device
Property Thin-provisioning: Yes
is set on LUN.