2

I've been playing around with my RPi3B lately and for whatever reason wanted to reformat my SD card. I'm unsure how I did it but now when I insert the card it says there is only 31mb of space. The card is 120gb but the computer is not recognizing anything but 31mb. How can I fix this?

Cheese
  • 41
  • 4
  • 2
    How are you determining the remaining size (windows or from the Pi)? What Distro did you burn to the SD card? – Steve Robillard Mar 21 '19 at 17:27
  • From Windows. I used cmd Diskpart to format and etcher to burn the card. – Cheese Mar 21 '19 at 17:44
  • 1
    Windows will only show the first partition, not the larger second partition. Assuming you are using Raspbian it will either autoexpand on first boot or the raspi-config utility has an option to expand the file system. – Steve Robillard Mar 21 '19 at 18:07
  • It no longer has a raspi os. Its just an empty 31mb – Cheese Mar 21 '19 at 18:33
  • It is not empty if you correctly flashed an OS to it using etcher. – Steve Robillard Mar 21 '19 at 20:44
  • 1
    try "burning" raspbian onto it again, if etcher claims the SD is 31MB then there's really something wrong with it - 31MB doesn't sound like anything raspberry pi would create (~40+ MB for the boot partition in all my pi's) – Jaromanda X Mar 21 '19 at 20:49
  • Etcher only recognizes the 31mb – Cheese Mar 21 '19 at 22:15
  • the SD card is absolutely broken then - I've had this happen to me, though in my case they (3 of them) ended up 1GB (out of 8) - I'll never buy cheap sd cards again :p – Jaromanda X Mar 21 '19 at 22:29

3 Answers3

2

A hard disk can be separated into several partitions each appearing as independent drive with its own letter in Windows explorer.

This can be done with an SD-card or USB flash drive, too, but it is normally very uncommon, except when an operating system is installed on the drive. There is typically a small drive of just a few 10MB for initial booting (e.g. UEFI), and at least one larger partition for operating system and data.

Now, this smaller partition is formatted with FAT, which Windows can understand. You formatted this partition, and it is empty now.

The larger partition is formatted with ext4 in case of Raspbian. Windows doesn't understand this, and so doesn't display it, or even assign a letter for it.

Go to disk management in Windows. In the lower half of the window, each physical hard drive is shown as row, with the partitions as blocks on it. You'll notice the small 30MB partition, and a large "unknown" one. Delete both, create a new partition over the entire space, and format it. After, you have the full capacity "back".

enter image description here

sweber
  • 516
  • 2
  • 3
  • Unallocated space and alternate letter drives don't show up only a single letter drive with 31mb of space – Cheese Mar 21 '19 at 20:17
1

Try formatting the SD with the sdformater:

https://www.sdcard.org/downloads/formatter_4/

Andreas Paxih
  • 55
  • 2
  • 9
1

This happened to me once, several years ago. I installed on a new 8GiB card, and it failed in a couple of days and was unformattable.

I contacted Sandisk, and was advised to return the card, to be replaced under warranty. I gather this is a known, but rare, problem.

See Raspberry breaks SD card -> 31 MB RAW

Milliways
  • 54,718
  • 26
  • 92
  • 182