2

I have configured by raspberry pi as a wifi access point using a 32GB SD card, and installed postgres. I would like to clone the SD card (from my mac) to smaller size SD cards (like 16GB, or potentially 8GB cards). Is this possible (knowing that I use mush less than 8GB space on the card)?

Is there something more to do than just usual dd commands?

I tried with an 8GB card, but it didn't work, although I got no error message.

Clémentine
  • 353
  • 2
  • 4
  • 15

4 Answers4

1

You can easily resize file systems and partitions using GParted to less then 8GB and then clone card to smaller one.

rav_kr
  • 456
  • 5
  • 12
0
  1. use gparted live make the partition smaller then 8gb

  2. use win32diskimager to make a image from the resized sdcard

  3. use win32diskimager to restore the small image to your sdcard

  4. use gparted live again to resize the sdcard so that you have all the space from your sdcard

0

I won't try this before but copying 8Gb to 16Gb is quite possible and easy. You could also use the un-allocated space as an extra space. Try to check here: [RaspberryPI 8Gb img to 16Gb]. It would really help!

In order to the un-allocated space, there are a few steps to follow.

The steps that I did:

  1. Copy the 8GB img to the 16GB storage drive/device using "Win32 Disk Imager".
  2. Boot you RaspberryPI using your old 8GB SD card or USB.
  3. Open LXTerminal and type or copy and paste "sudo apt-get install gparted".
  4. Connect the 16GB SD card or USB in the other USB slot.
  5. Type or copy and paste "gksudo gparted" in the LXTerminal. Wait for the GParted window will appear.
  6. In the drop menu located at the upper right side the GParted and select the 16GB SD card or USB.
  7. Click "Resize/Move" and move the GParted slider to the end.
  8. Click "Apply All Operations" to all apply the change you to the storage drive.
  9. Just close the GParted window and shutdown the RaspberryPI
  10. Remove the 8GB and keep the 16GB plug in the USB port.

The RaspberryPI will the display the text indicator in a startup but it will not continue in your desktop, but don't panic, it just detecting all the block and keeps all intact. I will restart in the second time, and it time that the RaspberryPI will boot to its desktop.

Check the storage if it increases in size/capacity, if "YES", congratulations, you made it and that's easy.

Greenonline
  • 2,969
  • 5
  • 27
  • 38
0

I've implemented an experimental option to shrink or expand Linux partitions in ApplePi-Baker. Maybe it's worth a try.