Difference between revisions of "Backup SD Image"

From SingletonMillerWiki
Jump to: navigation, search
Line 31: Line 31:
  
 
===Linux===
 
===Linux===
Coming Soon. Done: but needs writing up.
+
This uses the method given Raspberry Pi Easy SD Card Set Up referenced above: but in reverse. Any Linux machine can be used and it assumes the SD Card being backed up is not mounted. So if you only have one SD card you can't use your Pi, you have to use another Linux machine. However, if you have two SD cards capable of booting a Pi, use the one you aren't backing up to boot Pi and the backup the other, via a USB - SD card reader.
 +
 
 +
If you are using another Linux machine you can back it up to that machine or to anything, such as a NAS, that it can see. If your using your Pi it will have to be backed up to some form of extarnal storage, such as a USB HDD or a NAS.
 +
 
 +
The instruction here back up the SDd to a mount point on the Linux machine doing the backup.
 +
 
 +
Firstly mount the location that will receive the backup:
 +
 
  
 
== Regular Backup ==
 
== Regular Backup ==
 
If you make regular changes to your RPi its worthwhile spending the time creating these images. Tim spent backing up is always saved in rebuilding.
 
If you make regular changes to your RPi its worthwhile spending the time creating these images. Tim spent backing up is always saved in rebuilding.

Revision as of 12:11, 14 June 2012

At some point in your use of the RPi, you're going to think "I've made a whole heap of changes to my RPi build, what if it breaks and I lose everything? How do I stop that happening?".

The answer is 'you can't' hardware fails, power glitches, sudo rm -rf * , human error, all these types of thing can corrupt your precious SD card.

The solution is 'back it up'.

The ideal solution is to create an device image of your current SD card so you can completely rebuilt it rather than starting from a vanilla debian or fedora build.

Resources

http://elinux.org/RPi_Easy_SD_Card_Setup

Creating an SD Image

You've probably already used an image tool to burn your SD card from an process similar to Setup:RPI.

Windows

I used the windows tool win32-image-writer. win32-image-writer can also be used to create an image file.

  1. Shutdown you RPI using sudo shutdown -h now .
  2. Remove the power from the micro USB connection
  3. Remove the SD card from the RPi slot.
  4. Insert the SD card into your Windows PC card slot
  5. Run the win32-image-writer utility on the windows PC
  • Select the SD card in the device drop down. If you have more than one device, be careful to select to correct one.
  • Select the Imager Name to write to, make sure you select a *.img filename.
  • Press read button to burn a binary image of the SC card to the file.

The process is slow and the imager file generated will be approximated the same size as the SC card capacity. This is because the image is a binary clone of the SD card. The img file may be zipped to reduce its size after the process is completed.

Linux

This uses the method given Raspberry Pi Easy SD Card Set Up referenced above: but in reverse. Any Linux machine can be used and it assumes the SD Card being backed up is not mounted. So if you only have one SD card you can't use your Pi, you have to use another Linux machine. However, if you have two SD cards capable of booting a Pi, use the one you aren't backing up to boot Pi and the backup the other, via a USB - SD card reader.

If you are using another Linux machine you can back it up to that machine or to anything, such as a NAS, that it can see. If your using your Pi it will have to be backed up to some form of extarnal storage, such as a USB HDD or a NAS.

The instruction here back up the SDd to a mount point on the Linux machine doing the backup.

Firstly mount the location that will receive the backup:


Regular Backup

If you make regular changes to your RPi its worthwhile spending the time creating these images. Tim spent backing up is always saved in rebuilding.