Using CloneZilla to Create a Custom Recovery Partition

Has your friend just asked you to re-install windows for the 4th time? Or maybe your company has checkout laptops that need to keep a static image…. You ever wish that you could take a snapshot of your PC and capture that moment when everything was setup perfectly so you can restore it easily with just a few keystrokes? After all, a lot of the major Laptop manufacturers have such a recovery partition…why can’t we create our own custom restore image?

 

This is actually a project that I’ve been wanting to write about for awhile now, but I always seemed to hit a dead-end when trying to figure this one out on my own. Thankfully, Steve over at rmprepusb.com has figured out a way to make setting up your own custom recovery partition as simple as possible – both setting it up and creating/restoring the image! No need to re-image your PC or buy expensive software – In fact you can have your custom recovery partition setup within an hour!

 

Below is a great video detailing the process, courtesy of Britec09

 

While the video does a great job of covering the essentials to get you started, I wanted to cover the process myself and highlight some of the great features and customizble options available when setting this up. For instance, Don’t like the default boot image? We can change it! Want to hide the boot prompt from your end users? We can do that to. I’m also going to highlight a few roadblocks I ran into during my test installs, hopefully saving you a a bit of trouble.

Disclaimer! I highly recommend that you start out working with a PC image you can afford to lose. I have tested the below method to be working and functional in Windows XP, but ran into a few issues working with Windows 7 – namely images that were deployed via network installs or in virtual-box. Please take care to test the process before you implement this on your target machine!
You have been warned
!

[learn_more caption=”Step 1 – Create Your Recovery Partition”]

Create Your Recovery Partition

First things first, We need to create a separate partition for our Recovery Image & CloneZilla to reside.


In Windows 7…

1.) Start > R-Click  “Computer” > Manage

2.) Select:  Storage > Disk Management

3.) On your main OS Drive, R-Click and select “Shrink Volume

Shrink_volume

 

4.) Adjust the size of the shrink job to accommodate your backup image.

ShrinkVolumePage

 

If your used space on your C:\ drive is 18gb, shrink your volume by ~20gb just to be safe. It is important to note also, that these numbers do not reflect Clonezillas final compression of your backup image!

 

5.) Next, We will need to format the volume.

>>> R-Click on the free space and select “New Simple Volume”

NewSimpleVolume

 

6.) Finally, Click through the prompts to format your new recovery partition.

NewSimpleVolume_Format
I’ve left file and folder compression unchecked intentionally, simply because I know that CloneZilla will compress the backup image. I didn’t deem a slight increase in compression worth any stability issues that I may have encountered having 2 different forms of compression ( Windows partition compression & Clonezillas image compression). Probably me just being paranoid..but better safe than sorry when it comes to your data. 😀

 

In Windows XP

If you are using Windows XP, You will need to use the free EaseUS Partitioning Tool. Usually I would take the time to document the process…but once you run the tool, it should be pretty intuitive to figure out how to re-size your current partition and create your new recovery partition. That being said, If anyone runs into trouble here – let me know and I’ll update the post with some nice screenshots and directions 🙂

 

[/learn_more][learn_more caption=”Step 2 – Downloading The Required Software”]

Downloading the Required Software

 

There are 3 downloads you will need before we can get started…

  1. CloneZillaBackup.Zip(At the very bottom of the page)
  2. Winrar or 7-zip
  3. CloneZilla Live Files – (.Zip file preferably)

 

If you are not Sure which Clonezilla version to download, the below information should help.

 

i486
Single Core CPU. (Does not support PAE, Multi-Core, Hyper-threading or multi-processor)

amd64
Compatible on PC’s with AMD64, intel 64 or VIA Nano processors. Also compatible with Xen Hypervisor.

i686
Requires one more processors that support PAE ( Physical Address Extension ). Below is a list of support CPU’s

Intel Pro/II/III/4/4M/D
Intel Xeon
Intel Core
Intel Atom
AMD Geode NX
AMD Athlon (K7)
AMD Duron
AMD Opteron
AMD Sempron
AMD Turion
AMD Phenom

***For Most modern PC’s, you will want use the i686 Download of CloneZilla!

[/learn_more][learn_more caption=”Step 3 – Installing Grub4Dos & CloneZilla”]

Installing Grub4Dos & CloneZilla On Your Recovery Partition

 

If you haven’t already installed Winrar or 7-zip go ahead and do so now.

You should also have the x2 following .zip files downloaded as well.

CloneZilla_Grub4Dos_ZipFiles

 

1.) First we simply need to extract the contents of the CloneZillaBackup.zip file to our recovery partition.

CloneZillaBackup_RecoveryPartition

 

2.) Next, we need to extract the “live” folder from our clonezilla-live.zip file and place it @ Z:\clonezilla.

CloneZillalive_extract

 

3.) Now that our recovery partition folder structure is all set, we need to install the grub4dos boot menu. Simply run the InstallGrub4dos.cmd command and hit ‘y’ at the prompt to install it.
(In Windows 7 – Run as administrator)

Grub4Dos_InstallPrompt

 

4.) Finally, we need to reboot the machine and make sure the splash screen comes up properly and we are able to boot back into our Windows OS still. If you encounter any issues after the reboot, please take a look at the Troubleshooting section later on in this guide!

Upon successfully rebooting back into Windows, I recommend running the “hide.cmd” command to hide the important recovery partition system files from the end users. I also highly recommend checking out the Additional Features section if you would like to modify the splash image, change the splash screen timeout, etc.

[/learn_more][learn_more caption=”Step 4 – Backup Your Image”]

Backup Your Image

 

1.) On your new splash screen, select option 2.

CloneZilla_BackupYourImage

 

2.) After a few moments you will be prompted to name your backup image.

CloneZilla_NameImage


3.)
That is it! It will take about 10-15 minutes to create your recovery image
(now is a great time to grab a beer)

CloneZilla_BackupYourImage_Progress

 

When the backup is done, it will reside on your recovery drive @ Z:\clonezilla\images

 

For what it is worth, Clonezilla compressed my 10.6gb Windows 7 image down to 3.4gb! Your mileage may vary here, so I would start with a larger partition if possible and shrink the volume to suite your needs.

[/learn_more][learn_more caption=”Step 5 – Restore Your Image”]

Restore Your Image

 

1.) At the splash screen, hit F6 to restore an image.

CloneZilla_RestoreYourImage

 

2.) Next, select an image to recover.

Win7_ChooseRecoveryImage

 

3.) After a few moments, Clonezilla will begin the recovery process of your image.

Win7_Recover_Progress

 

That should be it! The recovery process will vary depending on the size of your initial backup image, but expect it to take ~10 minutes. When it is done, it should reboot and load Windows.

[/learn_more][learn_more caption=”Additional Features”]

Additional Features

 

Most of the below modifications come to you courtesy of  rmprepusb.com. I encourage you to check out the original authors tutorial for additional tips & tricks and to check out their huge library of other helpful Tutorials!

 

Cleaning up the Splash Screen

Copy & Paste following lines of code to the top of your menu.lst file.

If you want the menu entries to be invisible to the end user, You can also add the following line:

However, it is important to note that the black text will still be visible against a non-black background. I am working with the author currently to remedy this, but in the mean time – I have found that creating a background image with a logo in the center and a black background where the menu text would be will make the menu text essentially invisible to the end user.

Here is an example of the splash screen I setup for my Moms PC, using the above changes. The idea is that now whenever she says her pc image is trashed, I can just tell her ” Ok ma, just reboot your pc and hit F6 when you see the robot”. Tested this in Windows XP and it worked beautifully!
(For best results – use a 800×600 pixel image.)

Robot_SplashScreen

 

Change Splash Image

1.) Create a .bmp image in the \Clonezilla\  folder.

2.) Change the following lines in menu.lst to reflect your image name.

 

Change Splash Screen Timeout

Change the timeout value in menu.lst

 

Hide your Recovery Partition

To hide your recovery partition, you can use the free for home use version of EaseUS Partition Master Tool.

 

[/learn_more][learn_more caption=”Troubleshooting”]

Troubleshooting

 

In Windows 7: If you encounter the below after a failed restore operation….

CannotBoot_AfterRecoveryImage

You can boot to the windows recovery CD, Select Repair and choose command prompt.
Then run the following:

 

 

Or, If you encounter a grub command prompt after reboot, type in the following:

If you encounter the grub command prompt during every reboot, you will need to copy the menu.lst file from your recovery partition to the root of your C:\ drive.

 

If you encounter any other errors/issues along the way – please feel free to leave me a comment below or @ the original authors blog via rmprepusb.com.

[/learn_more]

 

Another big thanks to Steve over @ rmprepusb.com & Britec09. Check out both their sites for a huge library of helpful tutorials and videos!

 

  • dusf

    Could you please edit this so that it could be used to restore a custom Windows 8.1 image without affecting boot so that it will not negatively impact Ubuntu installed on the same drive?

  • Richard Lebelinski

    I have since after making my initial Recovery image installed a few programs and changed some settings, yet when I perform an (F6) Image recovery I’am presented with Windows with the additional programs in place.

    • Richard – Wish I could be more help, however I haven’t looked at this project in some time…

      I would reach out to the guy running the grub4dos page, he has a ton of great resources to help troubleshoot.

      Best of luck.

  • Makky

    How do you edit what partitions to make image of? I need partition #1 and #2. Recovery is #3.

  • scavenger

    If you’re having trouble getting Clonezilla to boot, giving an error trying to “mount aufs on /root/”, edit the entries in menu.lst so that every line that ends with:
    ocs_live_keymap=”NONE”

    instead should end with “union=overlay”, like this:
    ocs_live_keymap=”NONE” union=overlay

  • scavenger

    In case that you cannot boot windows due to missing boot/BCD (error 0xc000000f), this is because in later OS the BCD store is actually located in the System Reserved partition, the one leading the disk with 100MB-500MB of space, this is what I found to work for me; add this line at the top of the other two in windows boot code section in menu.lst:
    find –set-root –devices=h /boot/BCD && chainloader /bootmgr

Pin It on Pinterest