First we will create a .img
file of your SD card image.
Linux users can just use dd (the same command you probably used to get the image onto the SD card in the first place) or the dcfldd command (which shows the progress of the operation unlike dd). For example, to copy all contents off the device that represents your SD card into an .img file in your home directory:
You should find out the block size of your sd card first (using an improper block size can lead to issues later on... TRUST)
$ sudo fdisk -l /dev/mmcblk0