System/Hardware/Layout:
Goal:
Keep the 4 SATA HDDs spun down 24/7 (by means of
Proposed "Dangling Root" Method:
The Problem:
The original pool root dataset (
The Question:
Is there any mechanism to force the existing root dataset's dnodes/ZAP blocks (I hope I have the terminology right) to relocate onto the special vdev without destroying the pool?
Specifically:
I want to verify that
Constraints:
Thanks in advance for any insights on whether that 140KB can be forced onto the SSDs, or confirmation on whether I should accept the unmounted old root as "good enough" for spin-down purposes.
- OS: Proxmox
- Pool:
gimli(4×16TB 3.5" SATA CMR HDDs, RAIDZ1) - Current usage: ~21TB used, ~21TB free (mostly large media files + metadata)
- Planned: Add 2×SSD partitions as mirrored
specialvdev (sized appropriately) - Available temp space: 8×2TB 2.5" SAS drives (can build ~12TB RAIDZ2 scratch pool, insufficient for full 21TB copy)
Goal:
Keep the 4 SATA HDDs spun down 24/7 (by means of
hd-idle) unless genuinely reading file data. Directory listings, find, stat, zfs list, and any metadata probes must be served entirely from the SSD special vdev. Spin-ups are "expensive" (10min idle timeout) and must be avoided for metadata access.Proposed "Dangling Root" Method:
- Add special vdev, set
special_small_blocks=16K(or 32K, that's a separate problem for me to solve myself) - Create new dataset
gimli/main(post-special-vdev addition) and make sure thespecial_small_blockssetting is correctly inherited - In turn,
zfs send | receiveeach child dataset (loki/anime,odin/films, etc.) via the 12TB scratch pool intogimli/main/..., destroying originals after each transfer is completed - Set
mountpoint=noneon the originalgimliroot, mountgimli/mainat/gimli
The Problem:
The original pool root dataset (
gimli) is "empty" but retains ~140KB of (what I understand to be) directory ZAP objects allocated on the RAIDZ1 vdevs. While mountpoint=none renders it inaccessible to users, the data remains physically on the HDDs. I'm well aware that I'm being paranoid, but this feels "incomplete" - the HDDs still hold pool metadata that could theoretically be accessed if someone manually mounted the root or if ZFS internally references it somehow.The Question:
Is there any mechanism to force the existing root dataset's dnodes/ZAP blocks (I hope I have the terminology right) to relocate onto the special vdev without destroying the pool?
Specifically:
- Can the root dataset's indirect blocks be rewritten in-place to the special vdev (similar to how
special_small_blocksworks for new writes, but retroactively)? - Is there a
zpoolorzfscommand (even undocumented) that defragments/remaps a specific object's block pointers? - Or is the "unmounted root" method truly the only path when lacking 21TB of external temp space to destroy/recreate the pool?
I want to verify that
ls /gimli (which hits the new gimli/main root) will never trigger reads on the underlying HDDs, and that no ZFS administrative command (zfs list, zpool status, zdb, etc.) will touch the HDDs in order to access the old root's ZAP data.Constraints:
- Cannot destroy and re-create the pool fresh (no 21TB temp storage available)
- Must be verifiable proof that the root directory actually lives on the SSDs (e.g.,
zdboutput showing the data resides on the special vdev, not the RAIDZ1 disks)
Thanks in advance for any insights on whether that 140KB can be forced onto the SSDs, or confirmation on whether I should accept the unmounted old root as "good enough" for spin-down purposes.