From 2aa729e5d0013aff08444ac24e6c4d01dbdd4bda Mon Sep 17 00:00:00 2001 From: albertony <12441419+albertony@users.noreply.github.com> Date: Thu, 7 May 2020 23:46:12 +0200 Subject: [PATCH] Updated How to enable VSS for rclone (2) (markdown) --- How-to-enable-VSS-for-rclone-(2).md | 1 + 1 file changed, 1 insertion(+) diff --git a/How-to-enable-VSS-for-rclone-(2).md b/How-to-enable-VSS-for-rclone-(2).md index 1087690..c7bd904 100644 --- a/How-to-enable-VSS-for-rclone-(2).md +++ b/How-to-enable-VSS-for-rclone-(2).md @@ -62,6 +62,7 @@ Clarifications: - The shadow copy (snapshot) is read-only, due to the command line argument `-nw` ("no writers") specified to `vshadow.exe`. - The path `c:\snapshot\` is a temporary symbolic link only accessible while exec.cmd is running, you will see it in Windows Explorer until the sync is completed (but it is read-only). - The contents of `c:\snapshot\` that rclone sees, is a mirror image of `c:\`, meaning there will be a directory `c:\snapshot\Program Files` mirroring `c:\Program Files` etc. If this is confusing, read about improvements below. +- Upon successful return vshadow will print message "Snapshot creation done.". This just means everything went well: It created the snapshot AND executed our script AND the snapshot was automatically deleted. Upon failure it will print message "Aborting the backup..." but this does not mean anything, because there is no backup to abort (in read-only/no writers mode) so it is not skipping anything that it would else do on a successful run (see [source1](https://github.com/microsoft/Windows-classic-samples/blob/master/Samples/VShadowVolumeShadowCopy/cpp/util.h#L692-L697), [source2](https://github.com/microsoft/Windows-classic-samples/blob/master/Samples/VShadowVolumeShadowCopy/cpp/shadow.cpp#L881-L910) and [source3](https://github.com/microsoft/Windows-classic-samples/blob/master/Samples/VShadowVolumeShadowCopy/cpp/create.cpp#L154-L157) for proof). Error handling and robustness - Wherever the batch scripts are referenced, we prefix their names with `%~dp0` to make absolute paths assuming they are in the same directory as the script they are referenced from, and surrounding with double quotes in case there are spaces in the path. This will prevent any surprises when running from different working directories, e.g. "Run as administrator" is notorious for always setting working directory to `C:\Windows\System32`.