-
I read this: #14542 My confusion lies in blocks, records and files. The special vdev is said to accept "small blocks" (not files), and explanations point often to the a dataset's recordsize to explain what goes where. There's find and zdb commands floating about to help create histograms of file sizes and determine the optimal recordsize for a given dataset. Now, if I understand things right zfs uses variable recordsizes by default, up to the recordsize defined for the pool or dataset. So, say thats 128K, a file gets chopped up in 128K pieces and the final piece gets a smaller recordsize to accomodate for the leftover piece. I hope I got that right or I've been lying to a lot of people haha! Assuming I got that right, my question then is will those variable records (when <= small block size) go to the special vdev as well? The reason I ask is that I am duplicating (zfs send/recv) a dataset with 1M recordsizes (while preserving recordsize), and my special vdev with small block size set to 128K is filling up. This dataset contains almost exclusively 2 filesizes:
These are backups, each data file apparently has an 8k sidecar file. So, well I'm not sure what to make of this so I figured I'd ask and see if someone can help me understand? Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 7 replies
-
|
Beta Was this translation helpful? Give feedback.
-
Thank you! I guess I need to turn down my small_block_size 😁 . |
Beta Was this translation helpful? Give feedback.
-
Also you're wrong, all records are logically the same size after you exceed one record in a file; they might physically end up smaller if you have compression enabled, but logically it's still 128k or 1M or whatever. |
Beta Was this translation helpful? Give feedback.
special_small_blocks
property is applied to a block size after compression. So it may be a "variable record size" for a small file, or just a well compressed large block of a large file. Anything with on-disk size below the specified threshold will be written to special vdev.