An easy start

One of the things I like about the Raspberry Pi is the ease with which you can change the system you are using merely by swapping in a different SD card. When I start a new project, especially if I want to write it up later for others to use I like to start with a fresh install of Raspian. However, it is a bit tedious to have to go through the raspi-config settings, sudo apt-get udate and sudo apt-get upgrade every time, and also in my case to set up the connection to a local nfs share on my Synology NAS, and a fixed Wifi ip address.

The solution is to carry out all these processes once, and then to save the resulting SD card image, and use this as a starting point for new projects. Of course every so often, you need to update it again, but this can easily be done.

If you have a windows PC you probably use win32diskimager to write an image to your SD card. You can equally use this to save an image. The program likes to save to an existing image, or at least I can’t find a way of creating a new one from the program. However this can easily be done by right clicking in a suitable windows directory and choosing new -> text document. Rename the text document from New Text Document.txt to SDbackup.img and then you can use this as the document into which to read the image from the SD card.

Note you will have to set your PC to display file extensions for this to work, which is done in the Folder Options control panel in the View tab advanced settings. Untick the line Hide extensions for known file types and click OK

Place the SD card you wish to backup in a card reader attached to your PC, and note the drive letter when it mounts (in my case F:) Start up win32diskimager and select the drive for the SD card (F) and click the folder icon and navigate to your new SDbackup.img fileClick the Read button to copy the SD card to the new image file.readSdcard
In future, you can use this image file to re-write to your SD card when you want a new pristine operating system with which to start a new project.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s