Linux – How to reformat microSD cards that were created read-only

fat32formatlinuxmicro-sd-cardUbuntu

My company was burning some microSD cards (4000 of them) and the multi burning machine we were using gives us the option to make the microSD read-only.

I didn't know this was possible, but apparently it flips a binary switch in the microSD card.

We now need to reformat all 4000 of the microSD cards and start fresh. We cannot format them because they are read only. I am not using a SD adapter so the possibility of the lock switch is a non issue.

Gparted cannot format them and running this command:

sudo mount -o remount,rw  /media/48EC-B32A

… returns this error:

cannot remount block device /dev/sdb1 read-write, is write-protected

Is there any way to force format these or are they permamantly gone?

Best Answer

The SD card should be unmounted before attempting format.

You will probably need to use mkdosfs

for FAT16

mkdosfs /dev/sdb2 -F16

or for FAT32

mkdosfs /dev/sdb2 -F32
Related Question