Converting a VHD/VHDX to VHD/VHDX using block cloning without data copy.
This is proof of concept.
Make VHD/VHDX that shares data blocks with source.
MakeVHDX [-fixed|-dynamic] [-b<N>] [-sparse|-unsparse] <Source> [<Destination>]
Source Specifies conversion source.
Destination Specifies conversion destination.
If not specified, will use file extension
exchanged with ".vhd" when the source is ".vhdx", exchanged with ".vhdx" otherwise.
-fixed Make output image is fixed file size type.
-dynamic Make output image is variable file size type.
If neither is specified, will be same type as source.
-b Specifies output image block size by 1MB. It must be power of 2.
Silently ignore if output is image type that doesn't use blocks. (Such as fixed VHD)
-sparse Make output image is sparse file.
-unsparse Make output image is non-sparse file.
By default, output file is also sparse only when source file is sparse.
Supported Image Types and File Extensions
VHDX : .vhdx
VHD : .vhd
RAW : .* (Other than above)
- Source and destination must have placed on same ReFS v2 volume.
- Differencing type can not be source and/or destination.
- When cluster size is 64 KB, alignment will be 64 KB. If update it with some software, alignment will be break.
- Large block sizes may not be supported by some software.
- Output image will be large. This tool does not inspect file system free space in image, or zero-ed data block.
MIT License