Hi, to post a firmware image of my embedded linux computer to a friend I want to size it down.
System wise I did that already (only the really necessary stuff of Gentoo plus some configuration and addons related to the embedded system)...the problem comes with the size of the microSDcard I use: 32 GB.... The microSDcard (source) has two partitions (boot + the rest). The boot partition is the first partition and it is of a fixed and tiny size. The second partition contains the "rest": Gentoo. Currently the used space of this partition is also small. The image needs to be of a format, which makes it possble to 'dd' it onto a microSDcard (target) and afterwards use g/parted to resize/expand the second partition to the end of the microSDcard to get all storage space available. If I dd the source into an image I get all those zeroes also and the image only will fit onto a microSDcard (target) of at least the same size. If I dd each partition separately I get two files and the partition table is not copied...may be technically possible but not user friendly. How can I manage to get an image from my microSDcard (source), which only consists of the used space in a way that it can be put onto another microSDcard (target) in the waay described above? How can I acchieve that magic ? ;) :) Thank you very much in advance for any help! Best regards, Meino