Great informative post zoomzoom! And I would definitely have used this if it could be automated. As it seems the original post also requested automation the question remains: How can we reliably do a full backup of a running Windows 10 instance? What's the least bad option?
For backing up OS files, it doesn't matter which 3rd party solution one utilizes, there is no reliable way of backing up in use Windows system files, which is why one cannot be booted to the OS to make a backup of the OS partition, without introducing corruption to the resulting backups, of which will occur at some point.
To automate capturing an image with DISM, a script can be created to reboot the PC into WinRE, with a separate script in the WinRE.wim that executes upon loading WinRE to capture an image and once done, reboot the OS.
- This is the best and safest option to ensure backups remain corruption free and not an inconvenience for the user by having to rely on proprietary images or a Linux environment.
- Provided one has ensured the WinRE.wim has been saved to it's own Recovery partition (i.e. not the partition Windows is installed to), then even if the OS partition became corrupted, WinRE could still be booted into by hard resetting the system 2x once BIOS/EFI hands off to the Windows bootloader.
- Additionally, WinRE can be customized by the user, and is something I recommend everyone do.
- If one wants to be able to utilize their PC while capturing an image of the OS partition, Win10PE_SE can be utilized.
The built in "Backup and Restore (Windows 7)" cannot do a full system state backup to a FreeNAS SMB share without error. I assume that this type of full system state backup is similar to the "clone" you get using DISM. On Windows Server however the built-in system state backup option does work.
The same functionality exists in Windows 10, but is intended to back up user data, not the OS itself and is not a clone of the data, but files with a version date and time attached.
- The way in which images are captured, and what applications they used, changed from Win7 [ImageX] to Win8+ [DISM]. Also, the way it which Windows 10 "Resets" itself has been improved, as it now utilizes the WinSxS folder to reset itself, thereby keeping all drivers installed up to the last major update (essentially ever 3 months or so). This not only drastically improves reset times, but also solves the issue of OEM drivers that must be installed first, and prior to any other software or Microsoft updates , which created an issue prior to this new reset method.
- That being said, I will never recommend the Reset functionality, as you still lose all 3rd party software you installed, and restoring from a WIM image is far faster
- A Reset is also far more intensive and time consuming when compared to restoring a WIM image
The best partition layout for Windows is where the user data files and the OS are stored on separate partitions (just like storing
/home on a separate partition/disk on Unix based OSes) , such as the following (in a single HDD layout):
- BIOS:
- Partition 1: 260MB Boot Files
- Partition 2: Windows OS
- For most people, 128GB for the OS partition should be plenty
- Partition 3: User Data
- This houses the bulk of each user's data folders/files (Documents, Downloads, etc.)
- Within the User's data folder (C:\Users\<username>), right click on the data folders, select the Location tab, then enter the data partition's drive letter and user folder (D:\<username>\<data_folder_name>)
- The OneDrive directory is the exception to this, as the folder location must be set via the OneDrive program itself, and if already set up to use C:\Users\<username\OneDrive, it must be logged out of first, then re-setup.
- Partition 4: WinRE
- I recommend 2GB if you're planning on customizing it, otherwise 512MB is fine
- UEFI:
- Partition 1: 260MB EFI Boot files
- Partition 2: 128MB MSR
- Partition 3: Windows OS
- Partition 4: User Data
- I personally choose to store my user data on a 2nd SSD
- Partition 5: WinRE
- Partition 6: Recovery
- While one can store the recovery image (Base.wim) on the WinRE partition, I personally choose not to because I have an SSD, which requires the last partition be large enough for over-provisioning (at least 10% of the hdd size, plus whatever free space for the Base.wim and any additional appended backups... I reserve 75GB extra, plus the 10%, for a total of 168GB)
By the way, I would like to add that I've had difficulties getting "File history" to backup according to the schedule. It seems flaky at best.
I've never had an issue with it... are you setting it up via Settings -> Update & Security -> Backup -> More Options
- I believe it will only create a new version of a file if the previous version has been modified
I personally prefer creating a WIM image of my data HDD, as it requires far less storage space, however you do lose version history under the properties of any file/folder. I do use File History backup, but still create a WIM image of my data HDD every month.