Linux to ghost Windows

lsuacner

Expert Member
Joined
Jun 5, 2007
Messages
1,659
Reaction score
3
SLOW but saves disk space.
Backup
ntfsclone -s -o - /dev/hda1 | gzip -c > /mnt/hda2/name-of-image.img.gz
Restore
gunzip -c /mnt/hda2/name-of-image.img.gz | ntfsclone -r -O /dev/hda1 -

FAST but uses disk space.
Backup
ntfsclone -s -o - /dev/hda1
Restore
ntfsclone -r -O /dev/hda1 -

I have a 4G disk for windows and a 480 total for Linux. I back my windows up in +-5 minutes. I restored recently and it worked. Now I can basically boot Linux, run the command in the background with a script and restore to a fresh copy of Windows daily. I use it to play Warcraft and don't like having to sukkel with Windows.
 
Sounds interesting... will try it some time (although I haven't gone into Windows in a month :D)
 
A useful trick to reduce the image size is to write the free space on the partition with zero's like this:
cat /dev/zero > /path/to/freespace/file
rm /path/to/freespace/file

That way when you do that partition backup with dd and pipe it through gzip or lzop the freespace compresses to next to nothing while you still have a bit for bit backup of the partition.
 
Top
Sign up to the MyBroadband newsletter
X