I have a corrupted micro SD card which I accidentally pulled out. I want to search & fix any errors with fsck utility.
$ umount /dev/mmcblk0 $ fsck --help fsck from util-linux 2.29.2 fsck.ext3: invalid option -- 'h' Usage: fsck.ext3 [-panyrcdfktvDFV] [-b superblock] [-B blocksize] [-l|-L bad_blocks_file] [-C fd] [-j external_journal] [-E extended-options] [-z undo_file] device Emergency help: -p Automatic repair (no questions) -n Make no changes to the filesystem -y Assume "yes" to all questions -c Check for bad blocks and add them to the badblock list -f Force checking even if filesystem is marked clean -v Be verbose -b superblock Use alternative superblock -B blocksize Force blocksize when looking for superblock -j external_journal Set location of the external journal -l bad_blocks_file Add to badblocks list -L bad_blocks_file Set badblocks list -z undo_file Create an undo file $ fsck /dev/mmcblk0 fsck from util-linux 2.29.2 exfatfsck 1.2.6 Checking file system on /dev/mmcblk0. File system version 1.0 Sector size 512 bytes Cluster size 128 KB Volume size 59 GB Used space 25 GB Available space 35 GB ERROR: unknown entry type 0x86. ERROR: cluster 0x111ee of file 'expunged' is not allocated. Totally 260 directories and 3182 files. File system checking finished. ERRORS FOUND: 2. $ fsck -p /dev/mmcblk0 fsck from util-linux 2.29.2 exfatfsck 1.2.6 fsck.exfat: invalid option -- 'p' Usage: fsck.exfat [-V] <device>
-p option is invalid when it says in help that it is
Automatic repair (no questions)?
How do I fix my SD card then?