Steps For Successful Windows Backup Image and Restore

Author:
phil
Created:
Wednesday, December 21st, 2016
Last Updated:
Friday, December 23rd, 2016

Disclaimer: Accessing the information on this page means you agree to the Sites Terms of Service


The Windows Backup Image / Restore function is great when it works, but one of the most worthless pieces of junk software to come from Microsoft. For example, in Windows 10, they have moved the recovery partition (or at least one of the partitions) to the end of the drive. You would think that by now, MS would have some common sense and do the necessary steps required to create the backup to go onto another drive, but I digress, they just want your money.

This brings me to the list of steps that are required to get a successful Backup Image and Restore on Windows 7 and Windows 10. Nobody uses Vista and what's the point of 8, so I'm not going to mention them, however the steps should be fairly similar.

One final note is that I am going to skip over the exact how-to and assume you have somewhat of an idea of how to get around Windows. If you get stuck on a particular step, there's always google.com for that.

Who will use this?

In most cases, this process will be used for anyone who wants to upgrade to a different hard drive for whatever reason, without loosing the current system configuration. In other words, the folks who don't want to re-install Windows.

This falls into 2 categories:

1) Migrating to another drive whether larger, smaller or same size.
2) Upgrading a RAID 0 setup (Yes, you can very easily upgrade RAID 0 drives running Windows by using this process.)

Times I've tried without this process and failed:

I've had the backup/restore fail on Windows 10, going to an IDENTICAL drive
I've had the backup/restore fail on Windows 7, going to a BIGGER drive (some success, some failure)

It's impossible to go from a larger drive to a smaller drive WITHOUT this process, or at least without shrinking the windows volume first, and good luck shrinking it down far enough w/o turning off system restore at a minimum...

Disclaimer

A few disclaimers before we get started...

Raid 0

For the RAID 0 folks, this whole process comes with a disclaimer. Before you restore to a new upgraded RAID 0 volume, before you ever break your existing volume, TEST THE RESTORE ON A SINGLE DRIVE FIRST. Seriously... I don't know how many times I've failed to hold my tongue just right and the backup image will fail during restore, regardless of drive setup. I then have to go back into Windows for a minor tweak so I can create yet another image to try. You NEED to have the environment such that you can get back into Windows if you need to. Leave the existing RAID volume intact and restore to a single drive that is large enough to hold your restored system image. Make sure the image on the single drive works before you ever break your RAID 0 volume. Once you break it, there is NO GOING BACK. "But RAID 0 is two drives! How can it create an image for both?" Windows doesn't see RAID 0 as two drives, why would the backup image? You're making an image of the combined volume, not the individual drives. Windows doesn't see or care about the two drives which is the whole point of Firmware and Hardware level RAID. Just clearing that up for anyone who is doubtful about this process working for RAID 0. I know for a fact it works, I've done it.

Everyone Else

This is more of a lightbulb moment as opposed to a disclaimer... Don't do ANYTHING with the old drive, until you've successfully restored to the new drive. If anything fails during the restore, you can still switch back to the old drive and make adjustments if necessary and create a new image.

What You Will Need

Hardware

  • New Hard Drive
  • Second Hard Drive that is larger than the disk space used by the old drive (External USB Drive recommended)
  • USB Recovery Drive [or] Windows Installation DVD [or] CD for Recovery Creation Disk
  • If RAID 0, Second Internal Hard Drive that is larger than the used disk space of your old drive

Thoughts

You can save a backup image to a network drive. I've personally never gone that route, so I have no initial thoughts on it other than you might have network driver issues in the Windows PE Recovery environment when it comes time to restore the image.

Common Steps

Between Windows 7 and Windows 10, the steps are fairly common. There's one extra step you'll have to take with Windows 10 though since it has a partition at the end of the drive and if you're running in a RAID 0 setup, you'll have the obvious steps of breaking and re-creating the RAID volume (after you've tested your restore...).

Step 1 - Defrag -> Consolidate Space

The first step is to consolidate all free space on the drive. Get it all together. I use a program called "MyDefrag" because it's super simple and works well. It has an option specifically for consolidating free space too. Just make sure you don't install it with the "Scheduled Tasks" options because it apparently is too old for those to install correctly for Windows 10.

Mirror1 - Filehippo: http://filehippo.com/download_mydefrag/
Mirror2 - CNET: http://download.cnet.com/MyDefrag/3000-18512_4-10701976.html

Step 2 - Reduce Page File Size

Depending on how much physical memory you have, I'd recommend between 512MB and 1024MB of pagefile.

The reason we want to reduce the page file size is two fold:
1) Save some time by reducing the image size a bit (no need in copying over Gigs worth of a file that we don't need)
2) Move the new page file to the end of the consolidated data.

Without step 2, the page file can be "who knows where" on the drive and the only way to move it is re-create it or disable it altogether. I don't recommend disabling it, even for this venture. Windows is like a lost puppy w/o it's page file.

Step 3 - Disable Hibernate

You may already have hibernation disabled, but if not, open up an "Administrator" command prompt and type the following:

powercfg -h off

This will delete the hiberfil.sys file and open up some more room on the drive.

Step 4 - Disable System Restore

For Windows 7, right click "My Computer" and hit "Properties".
For Windows 10, right click the Start button and hit "System".

Next, click "System Protection" over on the left. You should be able to figure out how to disable system restore from here... If you can delete any existing restore points, I'd recommend to go ahead and clear those too.

Disabling and cleaning out the System Restore will not only reduce some space needed for the image, but it also gets rid of the "System Volume Information" that usually hangs out somewhere towards the middle or end of a hard drive.

Step 5 - Reboot

Time for a good old fashioned Reboot.

Step 6 - Consolidate Disk Space

Now that the Hibernate file is gone, Page file is smaller and the system restore points are deleted, we need to consolidate the free space again. Kick off your defrag and consolidate the free space.

After the defrag finishes, you'll need to take a look at where the files are located. The bulk of the files should be at the beginning of the disk and there should be nothing at the end of the disk. If there is, there will be problems. If there are any files in the middle, or spaced out a bit from the beginning of the drive, you should be fine. We just need as much free space to be open at the end of the drive as possible. If there are files at the end, Reboot and try running the consolidation again. You might have to run an actual defrag on it to get them to move. Reboot after each defrag to help free up any of the system files that won't move.

Step 7 - Shrink The Volume

Head over to "Disk Manager" and right click on the C:\ drive (Windows) partition. There will be an option to "Shrink Volume". Click it and wait. It will pop up with a box telling you the amount of free space it can free up. Just hit "OK" to let it shink it. It's all automated.

Windows 10 Specific Instructions (Skip to 8 for Win 7)

Once the Windows partition is shunk down, for Windows 10 we need to move that last partition (if it exists) up against the Windows partition so we can move all of the free space left over from the Windows Partition, to the end of the drive. The absolute best program I've found to do the job is called MiniTool Partition Wizard Free Edition. It runs inside windows and does an absolute fantastic job of moving partitions around. You can use it to shrink and extend volumes along with lots of other fun stuff, but for moving partitions, it's a LOT easier than dealing with gParted for this whole ordeal.

Mirror1: https://www.partitionwizard.com/free-partition-manager.html (Version 9.1 was available as of this writing)

I don't remember if you have to reboot afterwards but I don't think you do... If you do, the program will probably mention it.

Step 8 - Create The Image

Finally, after all of that, it's time to create the image. Head over to "Backup / Restore System Image", pop in your backup drive (External USB Hard Drives work the best for it), kick it off and walk away. It usually takes a good Hour or more to copy the image, depending on the speed of the USB drive.

Step 9 - Install The New Hard Drive

Step 10 - Reboot To Recovery

For this step, I'm going to assume you already have a Windows Recovery Disk or USB to boot from. If not, Google it.

Side note: You CAN NOT use a recovery image for a version of windows that is different than what you are using. For example, a Windows 10 Recovery will NOT work to restore a Windows 7 or 8 restore image. If you're doing 7, you must have a Windows 7 recovery. Same with 8 etc.

Step 11 - Restore the Image

Restoring the image is fairly straight forward. As long as your USB Hard drive (or the one containing the backup) is seen by the Windows PE recovery, it will automatically choose it and run with it.

Notes:

One of the steps talks about "formatting the drive". I always make sure it is checked, then click on the "Exclude Drives" button and exclude all drives except for the one I am putting Windows back onto. Just to be safe, I will unplug the power (if desktop) or remove from the device (if laptop) all hard drives I am not directly dealing with. This way I have 1) USB External Backup Drive 2) New Hard Drive 3) USB Recovery Drive. You won't need to worry about the USB recovery drive if you used a CD or the Windows install DVD to boot from.

Errors:

  • If the recovery environment won't see the drive you put the image on, try a different drive. If it's USB, try a different USB cable.
  • If you have errors restoring the image, try deleting the image on the backup drive and create a new one. The images are usually stored in \WindowsImageBackup.

This is the point where you now cross your fingers. It will either throw an error at the very beginning of the restore, or at the very end. It always sucks to get 100% through the restore, only to get an error... I've gotten lots of them though. Walk away and hope for the best. It usually takes an hour or so to restore.

Step 12 - Boot into Windows

Assuming everything went well, try to boot into windows.
A) If you are able to boot into windows after the image recovery restore phase, you're golden.
B) If it doesn't go into windows, there is only one reason I know of that will cause / fix it. Windows doesn't recognize the new drive (usually happens when upgrading to a newer SSD). In this case, you must boot all the way into safe mode, then reboot the computer.

Getting to safe mode on Windows 10 can be tricky since you can't actually boot into windows to tell it to go to safe mode... Lincoln Spector over at pcworld.com have come up with the solution though:

You’ll need the Windows 10 Recovery Drive, which you should make now, while your PC is still healthy. You’ll need a flash drive that you will use only for this purpose. Any files already on that drive will be deleted. To create the Recovery Drive, plug in the flash drive, open Control Panel’s Recovery tool, click Create a recovery drive, and follow the prompts you used to restore the image.

You might want to test this before you’re in a difficult situation: Boot the Recovery Drive and select your keyboard layout. Then select Troubleshoot > Advanced options > Command Prompt.

At the command prompt, enter these three lines, making sure to hit Enter at the end of each one:

c:
bcdedit /set {default} bootmenupolicy legacy
exit

Select Turn off your PC. Boot the computer and repeatedly press and release F8 until the Advanced Boot Options menu pops up. Then you can select Safe Mode or Safe Mode with Networking.

This forces windows to allow the legacy boot menu you might be used to with windows 7 and before.

If that doesn't work, then it's a completely different topic to mess with that I'm currently clueless about.

Move Partition on Windows 10 (Skip to 13 if on Win 7)

Go back into the Mini partition tool and move that last partition to the end of the drive.

Step 13 - Expand Free Space

Go into Disk Manager and right click the free space behind your Windows partition and choose the extend volume option. I don't remember if it's automatic or if you have to fill it in with a value, but I think it usually stops whenever it's at the end. Basically fill it up to the end of the drive.

Step 14 - Turn Everything Back On

Page File

Go turn up the page file. Set it back to letting Windows manage it or s

Hibernate

Open an administrative command prompt and type:

powercfg -h on

System Restore

Go back into the system properties and enable the system restore.

Step 15 - Enjoy!

Uninstall mydefrag if you don't want it and the mini partition tool (win 10) if you don't want it, but otherwise, you should be set!

Post Comment