[svlug] Re: A cheaper ghost

George Georgalis georgw at galis.org
Sat Jan 11 16:14:52 PST 2003


On Sat, Jan 11, 2003 at 03:38:51PM -0800, J. Paul Reed wrote:
>
>I have a duel boot (that's not a typo) laptop, and I'm just about finished
>installing Windows on it, much to my chagrin (need it for class).
>
>I've used VMWare before, and one of the coolest features was being able to
>move the virtual drive out of the way and back it up on CD-ROM so I could
>have a fresh Windows install every 6 months without much work.
>
>I was wondering if it would be possible for me backup this pristine windows
>partition to a file using dd (dd if=/dev/hdaX of=/tmp/win-backup bs=?
>count=?) and then store that on a CDROM or some such, and then at some
>point in the future, do "dd if=/tmp/win-backup of=/dev/hdaX".
>
>Will that work, as long as the partition doesn't move on the drive itself
>and I keep everything else the same?
>
>If so, how do I calculate the bs= and count= values?

yep, I do that. if you don't provide bs and count, it'll do the whole
partition. first defrag, then 'cat /dev/zero > /windowspartition/zero.txt'
till it runs out of space and remove /windowspartition/zero.txt
That'll help the compression, if you put bzip2 or something in the pipe.

On my setup I use the network, not a cdrom:

archive machine
nc -v -n -l -p 1234 > diskimage.dd.bz2

source machine
dd if=/hda1 | bzip2 -c9 | nc -w 5 -n -v 192.168.80.21 1234

might be a good idea to keep the partition table handy too. Oh, if you
uncompress the image you can mount it (read-only might be good) on lo
and just rsync the partition back in shape. (hope there is no typos
here)

// George

-- 
GEORGE GEORGALIS, System Admin/Architect    cell: 347-451-8229 
Security Services, Web, Mail,            mailto:george at galis.org 
Multimedia, DB, DNS and Metrics.       http://www.galis.org/george 




More information about the svlug mailing list