1

Topic: "BAD FAT" error while checking partition

Hello all,

I'm have a reasonable understanding of computers but you should go slow in your answers smile

I have a micro SD card from an old phone that I used to increase its capacity. I o not remember what I've done that time but took some tinkering so it is not a simple memory extension.

Now I want to clean the SD card and use it for my Raspberry Pi.

This is where you come in. I've tried to format thee card with various OSs and each throw an error. Only linux mint's USB Stick Formatter does not and says everything is successful. But it does not work.

So I tried to check the two partitions and got the attached report (couldn't attach, linking google drive below), the error it throws is below:

Bad FAT: cluster 14063 is cross-linked for \ANDROID\DATA\COMSPO~1.MUS\FILES\SPOTIF~1\STORAGE\AB\,..(. You should run dosfsck or scandisk.

https://drive.google.com/file/d/10lj1XA … sp=sharing

2

Re: "BAD FAT" error while checking partition

Contents of GParted details from Google Drive link

GParted 1.0.0

configuration --enable-libparted-dmraid --enable-online-resize

libparted 3.3

========================================
Device:           /dev/sda
Model:            TA WDC WD20EARX-00P
Serial:           WD-WMAZA7882848
Sector size:      512
Total sectors:    3907029168

Heads:            255
Sectors/track:    2
Cylinders:        7660841

Partition table:  gpt

Partition  Type             Start         End  Flags      Partition Name  File System  Label  Mount Point
/dev/sda1  Primary           4096      618495  boot, esp                  fat32               /boot/efi
/dev/sda2  Primary         618496   489084426                             ext4
/dev/sda4  Primary      489084928  3889375231                             ext4                /
/dev/sda3  Primary     3889376386  3907024064  swap                       linux-swap

========================================
Device:           /dev/sdb
Model:            Mass Storage Device
Serial:           none
Sector size:      512
Total sectors:    62945280

Heads:            255
Sectors/track:    2
Cylinders:        123422

Partition table:  msdos

Partition  Type             Start         End  Flags      Partition Name  File System  Label  Mount Point
/dev/sdb1  Primary             16    48828159  lba                        fat32
/dev/sdb2  Primary       48828160    62943487                             ext4

========================================
Check and repair file system (fat32) on /dev/sdb1  00:06:45    ( ERROR )

calibrate /dev/sdb1  00:00:03    ( SUCCESS )

path: /dev/sdb1 (partition)
start: 16
end: 48828159
size: 48828144 (23.28 GiB)
check file system on /dev/sdb1 for errors and (if possible) fix them  00:00:07    ( SUCCESS )

fsck.fat -a -w -v '/dev/sdb1'  00:00:07    ( SUCCESS )

fsck.fat 4.1 (2017-01-24)
Checking we can access the last sector of the filesystem
0x41: Dirty bit is set. Fs was not properly unmounted and some data may be corrupt.
Automatically removing dirty bit.
Boot sector contents:
System ID "mkdosfs"
Media byte 0xf8 (hard disk)
512 bytes per logical sector
16384 bytes per cluster
6 reserved sectors
First FAT starts at byte 3072 (sector 6)
2 FATs, 32 bit entries
6100992 bytes per FAT (= 11916 sectors)
Root directory start at cluster 2 (arbitrary size)
Data area starts at byte 12205056 (sector 23838)
1525134 data clusters (24987795456 bytes)
16 sectors/track, 4 heads
0 hidden sectors
48828144 sectors total
FATs differ but appear to be intact. Using first FAT.
Cluster 97534 out of range (2097152 > 1525135). Setting to EOF.
Cluster 97538 out of range (2097168 > 1525135). Setting to EOF.
Cluster 97559 out of range (67108992 > 1525135). Setting to EOF.
Cluster 97561 out of range (2228224 > 1525135). Setting to EOF.
Cluster 97569 out of range (134217728 > 1525135). Setting to EOF.
Cluster 97571 out of range (33554432 > 1525135). Setting to EOF.
Cluster 97577 out of range (33554944 > 1525135). Setting to EOF.
Cluster 97586 out of range (4194304 > 1525135). Setting to EOF.
Cluster 97587 out of range (134217728 > 1525135). Setting to EOF.
Cluster 97593 out of range (1). Setting to EOF.
Cluster 97602 out of range (4194304 > 1525135). Setting to EOF.
Cluster 97604 out of range (67108864 > 1525135). Setting to EOF.
Cluster 97621 out of range (1572864 > 1525135). Setting to EOF.
Cluster 97626 out of range (2097152 > 1525135). Setting to EOF.
Cluster 97629 out of range (16781312 > 1525135). Setting to EOF.
Cluster 97636 out of range (33554432 > 1525135). Setting to EOF.
Cluster 97643 out of range (4194304 > 1525135). Setting to EOF.
Cluster 97647 out of range (16777216 > 1525135). Setting to EOF.
Cluster 97649 out of range (67108864 > 1525135). Setting to EOF.
Cluster 97652 out of range (134217728 > 1525135). Setting to EOF.
Cluster 97666 out of range (33554432 > 1525135). Setting to EOF.
Cluster 97667 out of range (67108864 > 1525135). Setting to EOF.
Cluster 97681 out of range (16777472 > 1525135). Setting to EOF.
Cluster 97682 out of range (33816576 > 1525135). Setting to EOF.
Cluster 97703 out of range (1). Setting to EOF.
Cluster 97708 out of range (8388608 > 1525135). Setting to EOF.
Cluster 97714 out of range (16785408 > 1525135). Setting to EOF.
Cluster 97722 out of range (2162688 > 1525135). Setting to EOF.
Cluster 97725 out of range (2097152 > 1525135). Setting to EOF.
Cluster 97727 out of range (11010048 > 1525135). Setting to EOF.
Cluster 97737 out of range (16777216 > 1525135). Setting to EOF.
Cluster 97744 out of range (134217728 > 1525135). Setting to EOF.
Cluster 97752 out of range (67108864 > 1525135). Setting to EOF.
Cluster 97753 out of range (8388736 > 1525135). Setting to EOF.
Cluster 97759 out of range (10485760 > 1525135). Setting to EOF.
Cluster 97763 out of range (33554433 > 1525135). Setting to EOF.
Cluster 97775 out of range (9437184 > 1525135). Setting to EOF.
Cluster 97782 out of range (33556480 > 1525135). Setting to EOF.
Cluster 97785 out of range (8650754 > 1525135). Setting to EOF.
Cluster 550404 out of range (67108864 > 1525135). Setting to EOF.
Cluster 550412 out of range (167773184 > 1525135). Setting to EOF.
Cluster 550414 out of range (4194304 > 1525135). Setting to EOF.
Cluster 550432 out of range (17825792 > 1525135). Setting to EOF.
Cluster 550464 out of range (16777216 > 1525135). Setting to EOF.
Cluster 550468 out of range (4194304 > 1525135). Settin
grow file system to fill the partition  00:06:35    ( ERROR )

using libparted
libparted messages    ( ERROR )

Bad FAT: cluster 14063 is cross-linked for \ANDROID\DATA\COMSPO~1.MUS\FILES\SPOTIF~1\STORAGE\AB\,..(. You should run dosfsck or scandisk.

========================================
Check and repair file system (ext4) on /dev/sdb2

3

Re: "BAD FAT" error while checking partition

That error basically says the FAT file system on the SD card is corrupted.  As you say you want to clean the SD card, that error can be ignored.

Clean the SD card by writing zeros over the whole SD card with this Linux command:

sudo dd if=/dev/zero bs=1M of=/dev/sdb

(/dev/sdb is the device of the SD card).

After that use whatever tools you need to prepare it for use with your Raspberry Pi.