-
Notifications
You must be signed in to change notification settings - Fork 20
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
Crazy values #48
Comments
What does |
The method of creating the file wasn't included, but I'm guessing
mke2fs would write highly compressible data, but sparsely, so the compression doesn't get much chance to work, hence the tiny amount of zstd data (or prealloc data for some versions of mkfs.ext4). There would be a large extent count from that, but the extent counts are missing from the output. It looks fairly normal to me:
|
No, i copied from /dev/zero dd if=/dev/zero of=./zeroimg.img bs=1M status=progress102684950528 bytes (103 GB, 96 GiB) copied, 174 s, 590 MB/s^C compsize ./zeroimg.imgType Perc Disk Usage Uncompressed Referenced mkfs.ext4 ./zeroimg.imgcompsize ./zeroimg.imgType Perc Disk Usage Uncompressed Referenced Now i checked the disk space after each step, the compsize shows the disk usage correctly, because after a dd copy 2.99M the disk usage,and after mkfs.ext2 the disk usage become only 432M. |
mkfs.ext4 does hole punching, so the end result will usually be the same as the truncate:
|
I started to use btrfs compression to store disk images.. The values seemed to me incorrect so i made a try..
Created a file (approx 100G) with full zeroes..
The values seemed ok.
wrote few data to this file, in this case i created a loobpack device and made an ext4 formatted partition inside this file.
i unmounted. loopback detached..
This is what i got:
ant@voyager:/storage/4tb-s76/work$ ls -la zeroes.img
-rw-r--r-- 1 root root 103131643904 okt 12 19:49 zeroes.img
ant@voyager:/storage/4tb-s76/work$ sudo compsize zeroes.img
Type Perc Disk Usage Uncompressed Referenced
TOTAL 99% 516M 518M 518M
none 100% 516M 516M 516M
zstd 3% 76K 2.1M 2.0M
The text was updated successfully, but these errors were encountered: