I should clarify. I meant to say do that before putting anything on the drive. Otherwise you'll have to zero out the other space using the other method i mentioned.
Quote Originally Posted by Dave_Bechtel
>> If you want to make a compressed image of the drive you'd first want to dd if=/dev/zero of=/dev/hda the drive so that the unused space will compress very well. Then remote mount a file system...

--Do you realize what you just said there? That ***wipes out the entire drive,*** making it pointless to back up...

Quote Originally Posted by stonent
You can do the cat /dev/hda thing with ntfs, but you can't untar because Knoppix can't write to windows 2000 drives.

For some reason, copying an EXT2 drive with knoppix takes much longer. For that I type mount and read the pid of the auto mounter and kill -9 it. Then umount everything that is /dev/hdsomething or /dev/sdasomething

Also this will make the drives with identcal partitions so if you are going from a 20gb to a 40gb you'll have to make another partition or resize it using fips or something like that.

If you want to make a compressed image of the drive you'd first want to dd if=/dev/zero of=/dev/hda the drive so that the unused space will compress very well. Then remote mount a file system (samba or nfs) and
cat /dev/hda | gzip -9 > /mnt/remotefs/blah.img.gz (something like that, the > may not be necessary)

If you already have a full drive that you want to duplicate do something like dd if=/dev/zero of=/junkfile.tmp that will fill the empty space with zeros and then delete the junkfile.tmp after it dies from a full filesystem.