RPi SD cards

SD cards
The SD card is a key part of the Raspberry Pi; it provides the initial storage for the Operating System and files. Storage can be extended through many types of USB connected peripherals.

When the Raspberry Pi is 'switched on', i.e. connected to a power supply, a special piece of code called the bootloader is executed, which reads more special code from the SD card that is used to start up the Raspberry Pi. If there is no SD card inserted, it will not start. Do NOT push in or pull out an SD card while the Raspberry Pi is connected to the power, as this is likely to corrupt the SD card data (you might get away with it, but it is best not to).

The SD card must be formatted, or written to, in a special way that means the Raspberry Pi can read the data it needs to start properly. If you are new to this check the instructions, or buy a pre-formatted SD card.

One advantage to using an SD card like this is that you can have several SD cards, each with a different operating system, or a different purpose. Simply power off, switch cards, and reconnect the power. You have a different computer to play with.

Which SD card?


SD cards come in three physical sizes (see picture). The Raspberry Pi needs the largest one. The miniSD card and the MicroSD card can be used in a Raspberry Pi, but you will need an adapter / holder to fit it.

SD cards come in a range of storage sizes. You will likely need more than 2 GB.

There are other properties of SD cards that are not covered here. Read the Wikipedia article for those details.

Other SD card content
See the following links for other information:


 * Select a Distribution


 * Easy SD card set up


 * Advanced set up


 * Troubleshooting

Preinstalled SD cards
You might like to consider buying a preinstalled card; a wide range of branded SD cards preinstalled with operating systems are available. If you don't buy a preinstalled card, you will have to create one yourself. Check the SD Card setup page to help you make this decision. That page also shows where these cards can be bought from.

Verification
Users have listed working and non-working cards here. The SD Card Association suggests there are more than 400 brands across dozens of product categories and more than 8,000 models. These are just a few.

Is this reliable?
Unfortunately there is little scope for analysis of the failures given below. There are several reasons why a card may not work. You will notice that the same card may be shown as working and not working; the model numbers on cards do seem to be confusing.


 * the firmware / bootloader on early Raspberry Pi boards had a problem with Class 10 high speed cards. This has been fixed.
 * the drivers in some Linux distributions have been improved since the initial release
 * the Raspberry Pi can suffer from performance problems if peripherals are drawing too much power from the power supply; one of the consequences is errors from the SD card
 * unless using a preinstalled card, users have to copy a distribution image to the SD card. This might be considered more technical than the user has previously experienced, resulting in a faulty SD card
 * there are many cheap Chinese copies of (brand name) SD-Cards on the market, in addition they are often mislabelled as having greater capacity than they really have, see SanDisk counterfeit cards

... and of course, they may be faulty!

Technical Information
Note that manufacturers change their designs over time, even as the specs stay the same. (E.g. an ACME 8 GB class 4 card manufactured in 2011 might work, while one manufactured in 2012 might not.)

For this reason, please specify product numbers in the lists below, when possible.

You can also attach the following fields from your card's CID: cd /sys/class/mmc_host/mmc?/mmc?:* echo "man:$(cat manfid) oem:$(cat oemid) name:$(cat name) hwrev:$(cat hwrev) fwrev:$(cat fwrev)"

Working / Non-working SD cards
The table can be sorted using the triangles in the top row. Please add entries in the correct location, so that the initial sort is by Manufacturer, Type, Size and Class. Keep separate entries for working and non-working. Put your user name and date in the final column, so people can judge if the problem is still likely to occur.

Performance
The following results have been reported by Users.

Terminal Commands
To obtain the results in the table, type the following lines at a command prompt. If you are running the GUI windows, open the Terminal application.

The dd command is the Linux block copy command. It reads from the if= file, in the first case a block of zeros, and writes to the of= file, in the first case the file named test.tmp in your HOME directory (the ~/ means your HOME directory). The bs= gives the size of the data, and the count= gives the number of times this is repeated. sync ensures that the filesystem cache is flushed to have more realistic data. Please run it multiple times, one sample is not scientific enough.

Write speed

sync; time dd if=/dev/zero of=~/test.tmp bs=500K count=1024; time sync

Read speed

dd if=~/test.tmp of=/dev/null bs=500K count=1024

Delete the temporary file

rm ~/test.tmp

Kernel version

uname -a

External Benchmarks

 * http://www.sakoman.com/OMAP/microsd-card-perfomance-test-results.html
 * http://www.raspberrypi.org/phpBB3/viewtopic.php?f=2&t=4076

Is this reliable?
SD cards are given a rating (Class) by the manufacturers; the higher the rating the quicker the card. SD cards are usually used in a camera. The camera usually writes a block of data (a picture), then writes another. The SD card is tuned for this type of use. When used in the Raspberry Pi the data is written and read a lot more frequently, and from differing locations on the card. This difference in use means the manufacturers rating may not be as applicable for the Raspberry Pi.

SD card performance
The table can be sorted using the triangles in the top row. Please add entries in the correct location, so that the initial sort is by Manufacturer, Size, Type and Class

SD(DC|DX] Card Class 6 & 10 Hints with OverClockings
[|SD card usage Hints with OverClocking]