-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Compression not compressing files #10201
Comments
There are several factors here:
So if zstd can give you 77% data compression, there is a chance that your data won't be compressed by lz4 better than 87.5%. Please check that your data compresses better than ~80% (per-block compression in ZFS will be slightly worse). |
Thanks for your reply. I switched to I never noticed there is an underlying 87.5% "criteria" for compression... It is not documented in Oracle's admin guide. I finally found it in zfs command's man page. Please close this issue if you think problem is solved, or keep it to track the PR status. |
Glad to hear that! |
System information
Describe the problem you're observing
Compression seems not working.
I used a single HDD with ZFS for testing purpose and plan to deploy after the raid-z reflux codes are done. After months of use, I found that the compression seems not engaging.
Since I am not 100% sure, I designed a small test to compare with btrfs.
Describe how to reproduce the problem
A single MHT file will be used for demonstration, it contains texts and images, the file size is 12GB. The first portion(about 3 GB) is plain UTF-8 texts so the file is supposed to be recognised as "compressible".
First, I cut two partitions on a single HDD for testing.
Then, create filesystems with default options, after that
For ZFS, set
zfs set compression=on testZcomp
For BTRFS, mount with
mount -t btrfs -o compress=zstd /dev/sdc1 testBcomp/
Finally, copy the test file into each filesystem with
and
Results
Conclusion
As shown above, I assume the file is not being compressed at all. This problem might already exist before I upgraded to Ubuntu Focal Beta, if it is not reproducible, please tell me what more information I should summit.
Finally I want to thank you developers for creating this amazing file system, I suffered a severe data lost when using BTRFS due to bugs(even with Kernel 5.3!). ZFS is just the best FS. I also hope ZSTD could be soon implemented!
Include any warning/errors/backtraces from the system logs
The text was updated successfully, but these errors were encountered: