compress image afterwards on target machine?

Help
2006-05-08
2012-09-10
  • Albert Moben

    Albert Moben - 2006-05-08

    Is it possible to compress the image file after the transfer on the target machine, instead of compressing it while reading on the source machine? If that is possible, what is the command needed for the task on the target machine? I want the compressed image to be readable by g4l later on another computer without unpacking it first.

    I ask because I believe compressing my 40 GB image on a 3.6 GHz Pentium-4 would be much much faster than doing the compression on my old 166 MHz Pentium machine on which I want to backup an old harddrive. I started it there with compression turned on, just to estimate the required transfer time, but that would be measured in weeks rather than not hours, so it is very unaceptable. Transfer with no compression would take 7 hours, but it would be a pain to transport the image splitted over 10 DVDs.

     
    • Michael Setzer II

      First thing I would recommend, is trying lzop compression. Gzip compress on my 2.8ghz P4 machines uses like 90% of the CPU during the process. Lzop uses between 10 - 20%. The result is an image that is about 10% larger than gzip image, but it took about 1 hour for an 80GB drive verses 2 hours with gzip.

      Also, did you clear all the unused space on the drive. There are programs on the CD that will help with this. I did an image of an 80GB drive after dowing a clean install after wiping the disk. The image was 12.5GB. I then cleared out the unused space, and redid the image. Only 2GB. The g4l copies all sectors, and sectors full of nulls compress much smaller than sectors with random junk.

      As for compressing it afterwards, it would just be using the gzip or lzop (I believe). During the process, it runs it thru the compressor, so I don't see what difference it would make. Might be that you would have to same type of piping, since it isn't a compressed file inside an archive, but a stream.

      Probable have to cat the image and pipe it thru the compressor. Best to look at the script, and look at the lines that have the compression to see the exact syntax. But I would see what lzop does. I've used it on a 300Mhz AMD K6-2 with no problem.

      One final solution that might be even faster, would be to temporarily move the drive to the fast machine, and make the image locally.

       

Log in to post a comment.