When you image a drive with dd, you get a image usually of the same exact size of the drive. You can compress the image, but that is really Dependant on how many continuous null's or zeros their are on the drive. My question is, does another tool exist to only image the critical blocks of the drive. Such as with a fresh install of an OS, is it possible to only copy up to the last block utilized by the new os?
while I know dd doesn't have such abilities, does such already exist, and if it does then does that app use dd.
Yeah, I'm pretty sure it exists. CloneZilla uses dd, and only saves the used sectors. Have a read through the forums there and you should find mention of it. Otherwise download and read the code for their scripts.
you can check partimage as well.
Drive Image from PDQ used to be able to "understand" the filesystem and therefore it only needed to store the used bytes, even if the rest where not zero. Given that it was bought by another company and changed into Ghost. The following table from wikipedia shows a large number of system which do "Smart Copying" for a number of different file systems.
You should not create an image from the drive but make backup of the filesystem. With dump for example. It will copy only the blocks used in the filesystem. dd doesn't know anything about 'used' and 'free' blocks.
I'm not sure that you want an imaging program like
dd(1)
as much astar(1)
and a compression utility of your choice. Can you give us a bit more detail about what you're actually trying to do?For quick and dirty sort-of imaging of a Windows box, I boot a SystemRescueCD, and execute the following script (located on an external USB backup drive mounted on /mnt/backup):
Oh, the external drive is usually formatted NTFS, mounted with "-t ntfs-3g".
Basically, you want a tool that understands the filesystem and only saves blocks that are used. This is a good thing, but I kind of like having a full image of the drive (because I'm paranoid). In order to do that, and minimize the space needed for a compressed image, I use (on Windows systems that I want to image) the SysInternals 'sdelete' to write zeros to the unused sectors. That way the image is as compressible as it's going to get while still being a bit image.