Mark McLoughlin wrote:
Hey,
Okay, I follow you now. Doing:
- Create snapshot of os.img
- Resize it down to the smallest possible size
- Copy it to disk
- Resize it back up to the size of the disk
has the dual advantages of being able to install to the small possible
disk size and not copying unallocated blocks.
Sounds like a reasonable plan ... go ahead and give it a shot.
The reservation I'd have is if you're resizing down from 4G to 3G, the
1G of data blocks which have to be moved could potentially be at the end
of the image. In that case, you'd need a 1G COW area for the snapshot.
The part of my theory that is supposed to cover that, is an extra
minimize/truncate/sparsify_expand/maximize cycle on the image just before it
gets burned in the squashfs. Fingers crossed...
It'd be much better if you could resize filesystem as you're copying
it, and that should be possible, but you'd have to e.g. add support for
copying to resize2fs.
Sort of another way of saying "add in-flight-resize2fs support to e2cp" ;)
-dmc
Cheers,
Mark.
--
Fedora-livecd-list mailing list
Fedora-livecd-list(a)redhat.com
https://www.redhat.com/mailman/listinfo/fedora-livecd-list