I did something terrible to my SD card and I do not know how to format it.

I do not see the card with Nautilus, Gparted, nor fdisk. So I am not able to use answers from other questions I found here.

However, the output of $ ls -la /dev/sd* is

brw-rw---- 1 root disk 8,  0 bře 17 18:34 /dev/sda
brw-rw---- 1 root disk 8,  1 bře 17 18:31 /dev/sda1
brw-rw---- 1 root disk 8,  2 bře 17 18:34 /dev/sda2
brw-rw---- 1 root disk 8,  5 bře 17 18:31 /dev/sda5
brw-rw---- 1 root disk 8, 16 bře 17 18:34 /dev/sdb
brw-rw---- 1 root disk 8, 17 bře 17 18:34 /dev/sdb1
brw------- 1 root root 8, 32 bře 17 18:38 /dev/sdc

The sdc is the broken card I think - I can see sda and sdb with gparted and I know what they are.

How can I fix the card? Any idea?

  • 1
    Are there valuable data on the card, data that you want to recover? Or would you be happy to create a new partition table and file system (format the card)?
    – sudodus
    Mar 17 '17 at 18:14
  • @sudodus I would gladly wipe everything from the card.
    – matousc
    Mar 17 '17 at 18:17
  • Then I would recommend mkusb according to this link, askubuntu.com/questions/728289/re-use-of-ubuntu-live-usb/… . Ask if you need more help ... It possible that the card is damaged (internally). In that case mkusb cannot fix it, but often the problem is a damaged partition table. There could also be problems with the card reader, so please try another card reader (another computer?).
    – sudodus
    Mar 17 '17 at 18:20
  • When you can see the card as a mass storage device, in this case /dev/sdc, chances are good, that mkusb can restore it to a standard storage device.
    – sudodus
    Mar 17 '17 at 19:20
  • The link askubuntu.com/questions/877141/… will add some tips how to tell, what can stop you from using the card - please test several things before you give up and consider the card 'bricked'.
    – sudodus
    Mar 17 '17 at 19:29

Try different methods to restore the SD card to a standard storage device

  • Try if you can 'see' the SD card with the following command line,

    sudo lsblk -o model,name,fstype,label,hotplug,size,mountpoint
  • Try with mkusb according to the following links,

    Restore a USB pendrive or memory card to a standard storage device

    Format the sd card ...

  • If mkusb does not work, there may still be a few things to try. Did you try in another computer, with another card reader, with another operating system?

  • mkusb uses basic linux tools under the hood, and if they cannot see the card, I don't know of any other tool, that is available to regular users (you and me). There are special tools used by those who manufacture memory cards and USB pendrives, that might be available to some experts, that can get access at a very low level to the memory cells and maybe can re-program the internal processor of your card.

  • If still no luck, I would conclude that the SD card is damaged beyond repair, 'bricked'.

    Pendrive lifetime

Not the answer you're looking for? Browse other questions tagged or ask your own question.