Click to See Complete Forum and Search --> : Making vfat Images


Bios_Hakr
02-18-2001, 04:47 AM
To all,

I have a dual boot system. I have a swap file on /dev/hda1, /mnt/win98 on /dev/hda2, /boot on /dev/hda3 (the drive extends over 1024 cylinders so I needed a /boot under that), and / on /dev/hda4. Every 90 days or so, I reformat the win98 drive and reinstall. I want to save myself some time so here is what I am thinking:

Can I take /mnt/win98 and "tar" it? In its virgin form (win98, office 2k, norton utes, all sys patches) it is about 700meg. So here are the issues:
What command will "tar" everything?
Will it really tar the system files?
ARE YOU SURE?
Will I need to "gz" it also?
What do I need to do to restore it?


Thanks in advance.

ph34r
02-18-2001, 01:52 PM
tar doesn't do any compressing, so if you want a smaller resulting file, you may want to gzip/bzip2 it.


mount -t vfat /dev/hda2 /windows
cd /windows
tar cf /backup/windows/tar *
<go for coffee>
gzip /backup/windows.tar


OR, you could do


dd if=/dev/hda2 of=/backup/windowsimage.img
<go for coffee>

and then when you want to restore it


dd if=/backup/windowsimage.img of=/dev/hda2
<go for coffee>

The only way it wouldn't get system files is if the file were in use at the moment, but since you would be running linux at the time, everything should come over just fine.

[ 18 February 2001: Message edited by: ph34r ]

snowgod
02-18-2001, 05:47 PM
if you copied all of it before you did a reinstall, wouldn't you have all the crap you are trying to get rid of? unless you meant that you would reinstall all of it and then make a copy right after the reinstall, but if that happens, would you run into problem just copying it back over to the windows partition. I don't know if windows would like that, but it may. I'm not sure. this post may be retarded, but I was just confused, carry on...