I have a 64 GB SD card that has 15.6 GB of space used. I used GParted to shrink the partition, but I have no idea how to convert the two partitions /sda1 and /sda2 into an approximately 16 GB .img file.
Everytime I make an image file it turns out to be 64 GB. I'm pulling my hair out on this one since I can't find any solutions.
I've tried:
- Reformatting another drive that is smaller (I don't have any 16 GB drives).
- Gparted - Slimmed everything down, but the unallocated part still shows up as part of a second partition on Windows.
- Countless other things, web searches, etc.
How can I make this work?
The two partitions in question are apart of a bootable Raspberry Pi SD card.
I made a custom Raspberry Pi image that has some preinstalled server software (I want to host the shrunk file so users can install it, expand the filesystem and let the server run on their own). The problem I am facing is that using Win32DiskImager it copies the whole drive, so I want to find a way to copy it so that it only takes the 16 GB current size of the drive.
/sda2
) partition? Did you create the second partition afterwards? For which purpose?