89 - Automated Windows partition backup\restore boot menu using CloneZilla

site stats

Note: For a simple F11 to restore free solution, try Aomei One Key Recovery (free).

For a Tutorial for Windows UEFI systems see Tutorial 142

Watch My YouTube Video...

or watch Britec's video (with English narration)

RMPrepUSB Blog - please leave a comment or feedback on RMPrepUSB or this Tutorial (please mention Tutorial number).

If you want to make a bootable external USB Hard disk so that you can create or restore backups, see Tutorial 118.


This tutorial allows you to add some boot menu options to create a partition backup and restore option for your existing Windows hard disk. You do not have to re-format and re-install Windows to add a recovery partition.

Note: This system is not compatible with UEFI and GPT-partitioned disk!

Once set up, all the user has to do is press F4 for an automatic restore (with just one confirmation prompt only - but this can be removed if you prefer a fully automatic restore).

It uses CloneZilla and is based on a version posted by ndog37 on reboot.pro here. With this tutorial, you can quickly backup your copy of Windows at any time and then later restore any of the previous backup images. An XP backup takes approximately 5 minutes. Restoring an XP image takes approximately 1 to 5 minutes. Windows 7/8 will obviously take longer!.
The backup is made on the hard disk, so it is not suitable for off-line backups. The backup and restore options can also be fully automated so even your granny could restore Windows if it went wrong!

This tutorial assumes that your Windows OS is installed onto the first hard disk in your system, is the only copy of Windows on that hard disk and you have a backup partition on the first hard disk that has some free space to store the backup images in. If you have more than one partition containing Windows (e.g. dual-boot), then this tutorial will not work correctly and you will need to modify the menu.lst file substantially.

You can find out more about CloneZilla here. Boot parameters are here.
Because this method installs grub4dos, you will need to ensure your computer boots from the Master Boot Record.
If your Windows 7 or Windows 8 system uses UEFI booting, you will need to change the BIOS to CSM/MBR mode.

Clonezilla References


v1 2012-10-24 - First release - no Auto-Backup\Restore option
v2 2012-10-25 - 2nd version - added Auto-Backup\Restore option, split up long command line using grub4dos environment variables for easier editing\viewing, suppress keymap menu
v3 2012-11-01 - Added hotkey to menu, F4 for Restore from any Image, F6 for Auto-Restore


What we are going to do is to place a copy of Clonezilla on a spare backup partition on your hard disk, add some files and then install the grub4dos bootloader onto your hard disk.
After this has been done, your system will boot to a new grub4dos menu, as shown below (in this example we have a Windows XP system, so the menu shows Windows XP).

The menu.lst will automatically work out what partition is your Windows partition and what partition is the backup partition. When the menu is displayed, you will see which partition has been picked by the menu because the names listed in the menu will be changed automatically - e.g. sda1, sda2, etc. Thus it does not matter what partition arrangement you have as long as both the Windows and Clonezilla partitions are on the first disk (i.e. they can be in any order).

Linux disk notation:
sda1 = First hard disk (a), first partition (1)
sda2 = First hard disk (a), second partition (2)
sdb5 = Second hard disk (b), first Logical partition (5) - 1 to 4 are the primary partitions.

This is the grub4dos boot menu - after a 10 seconds countdown it will boot to Windows unless a key is pressed.

The Auto-xxxx options use an image name of 'IMG'. The other options allow you to define the image name yourself and you can make multiple images.


1. First we need to ensure that you have a spare partition on your hard disk that we can use to store the backup files and CloneZilla. This will appear on your system as D: and you will need to ensure that you have at least several gigabytes of spare space available on it. If you do not have a 2nd partition or you need to create a larger partition then you can use Windows Vista or 7 Disk Manager to delete, extend or shrink partitions. The Backup partition can be NTFS (preferred) or FAT32 and it can be a primary basic partition or a logical partition.
If you have a XP Windows system with no 'shrink' option in Disk Manager, you can download and use the free utility EaSeus Partition Master Home Edition.

>>> Before you proceed, check that the target system is a standard Windows system with two or more partitions
and check that the backup partition (e.g. D:) has lots of spare space.

PLEASE NOTE: The menu.lst will only detect the BACKUP partition if it is on the first, second, third or fourth internal hard drive (partitions 1-7).
You can edit the menu.lst if it does not detect the backup drive.

GPT disks: Clonezilla does not recognise or like GPT partitions. If your disk previously contained GPT partitions, CloneZilla may not work even though you delete all partitions and create new MBR partitions using Windows Setup. For this reason, it is highly recommended to use Windows DiskPart from a command shell to wipe the disk before you install a fresh copy of Windows. Typical commands are: SELECT DISK 0 - CLEAN - CONVERT MBR. Thanks to 'James' for this tip! See also 'GPT Partition Fix' below to save having to re-install Windows.

2. We need some tools, so on any Windows system (it does not need to be the target system), download the zip file CloneZillaBackup.zip from the bottom of this page and extract the contents to a new folder on your hard disk (I will call this new folder c:\xxx).

3. Download the CloneZilla ISO file from here - I used clonezilla-live-20120620-precise.iso. Use 7Zip or some other utility to extract the \live folder from inside the iso and copy it to the C:\xxx\clonezilla folder. Only three files are actually needed but you can copy the whole live folder if you like.

4. You should now have a folder structure like this (where xxx can be any name you choose):

C:\xxx\clonezilla\auroraxx.bmp.gz (two 80x600 compressed .bmp files)
C:\xxx\clonezilla\images\ (folder)

Installing the CloneZilla files onto a target system:

5. Now copy the the xxx folder contents (via a USB drive or via the network) to the backup partition (D: usually) of your target system - you should now have this folder structure (assuming D: is your backup volume)

D:\clonezilla\auroraxx.bmp.gz (two 80x600 compressed .bmp files)

6. To install grub4dos onto your target internal hard disk, double-click on the file D:\clonezilla\InstallGrub4dos.cmd - If you receive no error message then press Y and hit the <Enter> key.

7. It is time to reboot your system and check that you get the new menu and that you can still boot to Windows. Restart Windows and you should see the new boot menu, if you wait 10 seconds, it should then boot to Windows as normal. You can simply hit <Enter> to avoid the 10 second wait.

Note: If you are just dropped to a grub> command prompt, then try typing the following commands:

find --set-root /menu.lst
configfile /menu.lst

If you need to type this on every boot, then copy the menu.lst file from the backup D:\ drive to the root of the C:\ drive.
Note: If, in future, you change this C:\menu.lst file, remember to save a copy of it on your backup drive D: also, in case the C: copy gets deleted.

If your system does not show the menu (or indeed any change) then it may be that the system is set up for UEFI booting. In which case you will need to change the BIOS settings for CMS\MBR booting.

8. When the system has rebooted to Windows, double-click on the file D:\Hide.cmd to hide the \clonezilla folder and a few of the grub4dos files - only the D:\UnHide.cmd file should now be visible in Windows Explorer (unless you have changed the Folder View default options).