Howto set ZFS recordsize attr on storage volume creation?

Is there any way to set some ZFS dataset attributes
for example recordsize
on container/storage volume creation?
Is there an option to assign specific ZFS dataset to storage volume?


OK so we must wait for it

What is the proper order
1.create zfs dataset set recordsize and then lxc create volume
2.or opposite - lxc create volume and zfs set recordsize


Recordsize is mutable, but changing recordsize won’t change the size or layout of any blocks which have already been written to the dataset—only for new blocks as they are written.

I wonder if we choose option order 2 according to above quote we do sth wrong?


LXD will refuse to create a volume if the dataset already exists, so let LXD create it, then zfs set whatever you want.