background preloader

How to Clone Raspberry Pi SD Cards Using the Command Line in OS X - Tuts+ Computer Skills Article

How to Clone Raspberry Pi SD Cards Using the Command Line in OS X - Tuts+ Computer Skills Article
The Raspberry Pi runs from an operating system stored on a Secure Digital (SD) card and many different operating systems may be employed. Storage is relatively inexpensive, can be created (flashed), recreated, written to and overwritten with ease. On the one hand, this is an advantage of the Pi. On the other, the experimental nature of the Pi means more time flashing SD cards. This tutorial shows you how to use a Mac to clone any Raspberry Pi SD card which is particularly useful when you have your OS set up just as you want it. The Raspberry Pi is somewhat different to the computing, to which most of us have been accustomed, of the last two decades. With almost two and a half million units sold–in little over a year since its launch–and with its focus on getting kids (adults?) Being able to experiment, play and break things is all part of the fun. Cloning is the process of making an exact copy. Open Terminal and enter the following command to locate your SD Card:

debian - How do I backup my Raspberry Pi? If you want to preserve all of the data, you will probably have to create a disk image. Furthermore, Windows cannot recognize typical Linux filesystems, so you probably won't even be able to see your files, when you plug in your SD card. Creating a disk image will preserve not only files but also the filesystem structure and when you decide to flash your new SD card, you will be able to just plug it in and it will work. On Linux, you can use the standard dd tool: dd if=/dev/sdx of=/path/to/image bs=1M Where /dev/sdx is your SD card. On Mac, you can also use the standard dd tool with a slightly different syntax: dd if=/dev/rdiskx of=/path/to/image bs=1m Where /dev/rdiskx is your SD card. (using rdisk is preferable as its the raw device - quicker) To find out which disk your device is type diskutil list at a command prompt - also, you may need to be root; to do this type sudo -s and enter your password when prompted. Option 1 Option 2

Related: