On Tue, Mar 07, 2017 at 12:11:00AM +0000, GiaThnYgeia wrote: > I am not very confident I am doing this right and it seems wrong, I > can't locate any documentation that results into proper options. > I tried backing up an 8gb USB that has 2 partitions in it, one had 1.7gb > of data on it. > I used dd if=/dev/sdb of=usbfilename.iso > The resulting image was the full size of the disk. > To test the validity I restored reversing the order of the filenames > if/of but that took for ever and it was a hog on resources. After a > while I just gave up and killed the process. I looked at the disk and > it seemed complete with all files in tact, so maybe I killed it > somewhere in the verification process. > So I used a program called etcher which I have used with 100% success in > the past and was surprisingly fast in burning images. > It took for ever as well, eventually it run a verification routine and > it was done. > Is there someway one can avoid creating such a large iso for no reason, > when the filesize is a fraction of the whole disk. One way I thought of > was to shrink the partitions to just about 99% full, and leave the blank > part of the disk as not allocated. Would that help? > Is there some fancy command line that does just that? >
Most of the replies seem to have assumed you didn't really want to back up to an ISO file system, eg to write to a CD, DVD or Blu Ray. Just in case that's wrong and you actually did, you'll want the growisofs command line tool or the brasero GUI tool. growisofs is in a package of the same name, as is brasero. growisofs can definitely let you choose whether to just generate the .iso file, or to also burn it to a disc. brasero also can I THINK, certainly it can burn CDs / DVDs. In both cases the .ISO that is generated will be big enough to accommodate the data actually on the source disk (or SSD or USB or whatever) and no bigger. Mark