Linux – Cannot reformat Micro SD Card

gpartediolinuxpartitionsd card

I need to reformat my micro SD card, however I am having some issues with it. When I go the card on my computer, it displays the following message:

The folder contents could not be displayed Sorry, could not display
all the contents of "5390-A1C4": Error when getting information for
file '/media/username/5390-A1C4/N└G1°l;╓.u▌%': Input/output error

I then try to open gparted to attempt to format it, but it only loads and does not open gparted.

I am using a micro sdhc named 5390-A1C4 mounted /media/username/5390-A1C4 with a filesystem type of msdos. My OS is Linux Mint. It is mounted at /dev/mmcblk0p1 and the device is /dev/mmcblk0.

Any help with solving this issue is appreciated.

Best Answer

You may have it corrupted. With luck it is not definitively damaged.

The better way to deal with it is "zeroing it" and defining everything anew.

For that we zero it with dd:

sudo dd if=/dev/zero of=/dev/mmcblk0 bs=512 count=2

where /dev/mmcblk0 is the device where it is normally mounted. (/dev/mmcblk0p1 is actually the partition)

After the dd you can repartition it and format it again.

Related Question