On 5/17/19 3:18 PM, Sean Fagan wrote:
On May 17, 2019, at 3:37 AM, Peter Tribble <[email protected]> wrote:
What happens in the case where someone uses 'zpool create -d', which disables
the lz4 feature?
I changed it to default to ZIO_COMPRESS_ON, and I will assume it’s using the
legacy compression then.
(Since "zfs create -o compression=lz4 tank/DS2" failed, but "zfs create
tank/DS1" succeeded, and a
1g file from /dev/zero occupies only one block on the dataset.)
I’m using ZoL on ubuntu for my testing here.
Sean.
Writing a file of all zeros doesn't test the compression, since if
compress != off, we check for the 'all zeros' case and write a hole,
rather than actually allocating space.
If you write something else compressible, you should be able to use zdb
to see if it ended up using lzjb or lz4.
--
Allan Jude
------------------------------------------
openzfs: openzfs-developer
Permalink:
https://openzfs.topicbox.com/groups/developer/Tcfdc8da2da71e1c0-M0f7a74655b1f687ef21b419d
Delivery options: https://openzfs.topicbox.com/groups/developer/subscription