DiskShadow.exe is a new tool that shipped with Windows Server 2008 and it allows you to create and restore shadow copies (snapshots). The tool is similar to vshadow (a free tool that ships with the Volume Shadow Copy/VSS SDK), but it has a diskpart-like interface.
You can invoke DiskShadow from a cmdline, or you can pass a script to it using the command “diskshadow -s script.txt”
Below, i will show you an example script to back up all VMs of a Hyper-V Host. First, we need to know the ID of the VSS writer for Hyper-V. To do that you need to invoke the command “list writers” from diskshadow (or from vssadmin). Once you parse its content, look for this GUID as per below underlined text.