New
#1
Offline image backup of OS: Robocopy ok?
Hi there!
I would like to do an offline image backup of my OS-drive. I'm only interested in the OS itself. The data is backed up separately (and resides on a different drive). For high security, I'd like to avoid using any third party software. I will be installing win 10 using the latest iso-image downloaded from Microsoft. My question is:
If I boot up on a standard WinRE USB-stick (created in Win10 as usual): Can I just do a Robocopy to get an image backup into a VHDX file, ie a backup that is later restorable and bootable?
So basically to do a backup:
1) Boot up WinRE from a USB-stick and into the command line
2) Create VHDX-file using Diskpart and attach it to a drive letter, say V:
3) Robocopy /MIR /COPYALL C:\ V:\
I will copy all three partitions like this, ie the EFI System Partition, the OS partition itself and the recovery partition.
If I backup the OS like this, can I then later restore a bootable OS by doing the reverse (on all three partitions, first recreating those partitions with the same sizes), ie roughly like this (except I will create 3 partitions with same size as before, not 1 partition):
1) Boot up WinRE from a USB-stick and into the command line and open Diskpart
2) select disk 0
3) clean
4) create partition primary
5) active
6) format fs=ntfs quick label="OS_DRIVE"
7) assign letter=C
8) Mount backup VHDX-file using Diskpart and attach it to a drive letter, say V:
9) Robocopy /MIR /COPYALL V:\ C:\
10) Perhaps a call to bootsect to set a bootsector for C:\ ?
Will it work to boot the restored OS?
Will it work restoring to another host? Ie just to boot that host and then install the specific drivers necessary to make the restored host work well.
I know this looks very manual and rather complicated. The reasons I'm backing up in this particular way are:
* I want to avoid third party software to minimize dependencies I have to trust. I only want to have to trust Microsoft in this case.
* I just want to do this backup 1 time so I have a standard image of a configured host. I can then use that image/backup to reflash any of my hosts easily. Ie I can reinstall Windows 10 easily and with all my additional time consuming OS customizations intact.
* I would have loved to use "Backup and restore > Create a system image" in Windows 10, but unfortunately I've had mixed results. Sometimes when I restored to another host (using a usb stick created with "Recovery Media Creator" in Windows 10), Windows refused to restore the image with cryptic error messages. Also, I've heard some people say not all data was copied when Windows did the backup. I just thought that with Robocopy, I can be sure to really copy ALL the files without missing anything.
I guess, at heart, the question is: Is there any functional difference between copying all the files of a partition vs an image backup (especially when booting/doing the backup up in a WinRE env when the OS files are not locked/used by the OS and are in a consistent pre-boot state)?
Feel free to send very technical links, I love that :)
Very greatful for any help as I've been wondering about this for some time! And a happy new year to all of you!
Cheers,
Yukata
Last edited by Yukata; 01 Jan 2021 at 06:27.