-
Notifications
You must be signed in to change notification settings - Fork 40
Add abbility to do balancing only on files smaller than minimum ZFS block size #64
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
Comments
I don't really understand the logic or reasoning behind this, but feel free to create your own version of the script in this repo to achieve it :) |
IMO this only has limited utility. When adding a special device, you want both metadata and small blocks to be present. Having the metadata on the main pool would negate the performance benefits somewhat. Might as well go through the whole pool. |
@AT-StephenDetomasi it depends. If you started with no special dev and add data, then what you said is correct, you would want to rewrite everything to guarantee the metadata gets moved to the special dev. If the pool has a special dev from inception, but you change the small block size at some point, the file size limit becomes extremely relevant. In this case all metadata would already be on the special dev and you would be targeting only those files affected by the small blocks change, which could save hours or even days of data shuffling. |
Fair point, I hadn't thought about that particular situation. I can understand it's utility a bit more now. |
Uh oh!
There was an error while loading. Please reload this page.
I would guess it would help to only go through files with a filesize smaller that a certain value. A good place to start would be the block size of ZFS pool: zfs get special_small_blocks <pool_name>. Normally this is 128K.
So just add the check before doing anything with the file as wrinting those bigger files back and forth is just a waste of time. :)
Also given the small file size in the above case, this would work even better with a small (1GB) RAM drive and read the files there, then move them back from RAM disk.
The text was updated successfully, but these errors were encountered: