Submit #3254
closed[PATCH] Add initial multi-volumes support for HAMMER2
0%
Description
This commit adds initial multi-volumes support for HAMMER2. Maximum
supported volumes is 64. The feature and implementation is similar to
multi-volumes support in HAMMER1.
See commit message in below for details.
https://leaf.dragonflybsd.org/~tkusumi/diff/0001-sys-vfs-hammer2-Add-initial-multi-volumes-support-fo.patch
The patch applies on top of below commit or after.
064b66eab3015e74bb4b2ab05de363471dd314e6 ("usr.sbin/fstyp: Minor HAMMER2 fixes")
If no comments, I'll commit this in another week or so.
Updated by dillon about 4 years ago
- Assignee set to dillon
This looks very nice! And it also looks like you are validating the volume set by checking that the fsid uuid matches. I did a quick review and came up with the following:
- In hammer2_get_volume() you return a non-NULL vol in the case of failure, because 'vol' is assigned inside the loop. This definitely needs to be fixed to avoid corrupting the filesystem when the volume set is incomplete.
-Matt
Updated by tkusumi about 4 years ago
I've uploaded v2.
https://leaf.dragonflybsd.org/~tkusumi/diff/0001-sys-vfs-hammer2-Add-initial-multi-volumes-support-fo.v2.patch
- Changed hammer2_get_volume() to panic if a volume happens to be not found.
- A few other minor changes/cleanups.
Updated by tkusumi about 4 years ago
- Changed hammer2(8) "volhdr" to print all volume headers (not just root volume).
- A few other minor changes/cleanups.
Applies on top of the current master.
Updated by tkusumi almost 4 years ago
- A few minor changes/cleanups.
Updated by liweitianux almost 4 years ago
- Status changed from New to Closed
Committed in 0b7381572b131c74051832dc251604e7f77b5a54.