====== Seagate Exos BadCRC ======
System startup:
ahci 0000:06:00.0: AHCI 0001.0301 32 slots 1 ports 6 Gbps 0x1 impl SATA mode
ahci 0000:06:00.0: flags: 64bit ncq sntf ilck pm led clo only pmp fbs pio slum part
scsi host0: ahci
ata1: SATA max UDMA/133 abar m2048@0xfcd01000 port 0xfcd01100 irq 36 lpm-pol 4
ahci 0000:06:00.1: AHCI 0001.0301 32 slots 2 ports 6 Gbps 0x3 impl SATA mode
ahci 0000:06:00.1: flags: 64bit ncq sntf ilck pm led clo only pmp fbs pio slum part
scsi host1: ahci
scsi host2: ahci
ata2: SATA max UDMA/133 abar m2048@0xfcd00000 port 0xfcd00100 irq 38 lpm-pol 4
ata3: SATA max UDMA/133 abar m2048@0xfcd00000 port 0xfcd00180 irq 39 lpm-pol 4
...
ata1: SATA link down (SStatus 0 SControl 300)
ata2: SATA link up 6.0 Gbps (SStatus 133 SControl 300)
ata3: SATA link up 6.0 Gbps (SStatus 133 SControl 300)
ata2.00: ATA-10: ST2000NM0008-2F3100, SN02, max UDMA/133
ata2.00: 3907029168 sectors, multi 16: LBA48 NCQ (depth 32), AA
ata2.00: Features: NCQ-sndrcv
ata2.00: configured for UDMA/133
ata3.00: ATA-10: ST2000NM0008-2F3100, SN02, max UDMA/133
ata3.00: 3907029168 sectors, multi 16: LBA48 NCQ (depth 32), AA
ata3.00: Features: NCQ-sndrcv
ata3.00: configured for UDMA/133
scsi 1:0:0:0: Direct-Access ATA ST2000NM0008-2F3 SN02 PQ: 0 ANSI: 5
sd 1:0:0:0: Attached scsi generic sg0 type 0
sd 1:0:0:0: [sda] 3907029168 512-byte logical blocks: (2.00 TB/1.82 TiB)
sd 1:0:0:0: [sda] Write Protect is off
sd 1:0:0:0: [sda] Mode Sense: 00 3a 00 00
sd 1:0:0:0: [sda] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
sd 1:0:0:0: [sda] Preferred minimum I/O size 512 bytes
scsi 2:0:0:0: Direct-Access ATA ST2000NM0008-2F3 SN02 PQ: 0 ANSI: 5
sd 2:0:0:0: Attached scsi generic sg1 type 0
sd 2:0:0:0: [sdb] 3907029168 512-byte logical blocks: (2.00 TB/1.82 TiB)
sd 2:0:0:0: [sdb] Write Protect is off
sd 2:0:0:0: [sdb] Mode Sense: 00 3a 00 00
sd 2:0:0:0: [sdb] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
sd 2:0:0:0: [sdb] Preferred minimum I/O size 512 bytes
sda: sda1 sda9
sd 1:0:0:0: [sda] Attached SCSI disk
sdb: sdb1 sdb9
sd 2:0:0:0: [sdb] Attached SCSI disk
And issue:
[ +0.000000] ata2.00: exception Emask 0x10 SAct 0xf8 SErr 0x2c0101 action 0x6 frozen
[ +0.000043] ata2.00: irq_stat 0x08000000, interface fatal error
[ +0.000020] ata2: SError: { RecovData UnrecovData CommWake 10B8B BadCRC }
[ +0.000023] ata2.00: failed command: WRITE FPDMA QUEUED
[ +0.000017] ata2.00: cmd 61/08:18:c8:09:00/00:00:00:00:00/40 tag 3 ncq dma 4096 out
res 40/00:ff:81:00:00/00:00:00:00:00/40 Emask 0x10 (ATA bus error)
[ +0.000046] ata2.00: status: { DRDY }
[ +0.000016] ata2.00: failed command: WRITE FPDMA QUEUED
[ +0.000017] ata2.00: cmd 61/08:20:c8:0b:00/00:00:00:00:00/40 tag 4 ncq dma 4096 out
res 40/00:00:00:4f:c2/00:00:00:00:00/40 Emask 0x10 (ATA bus error)
[ +0.000046] ata2.00: status: { DRDY }
[ +0.000015] ata2.00: failed command: READ FPDMA QUEUED
[ +0.000017] ata2.00: cmd 60/20:28:78:55:6f/00:00:36:00:00/40 tag 5 ncq dma 16384 in
res 40/00:00:00:4f:c2/00:00:00:00:00/40 Emask 0x10 (ATA bus error)
[ +0.000045] ata2.00: status: { DRDY }
[ +0.000933] ata2.00: failed command: WRITE FPDMA QUEUED
[ +0.000423] ata2.00: cmd 61/08:30:c8:45:e0/00:00:e8:00:00/40 tag 6 ncq dma 4096 out
res 40/00:01:00:4f:c2/00:00:00:00:00/00 Emask 0x10 (ATA bus error)
[ +0.000742] ata2.00: status: { DRDY }
[ +0.000373] ata2.00: failed command: WRITE FPDMA QUEUED
[ +0.000361] ata2.00: cmd 61/08:38:c8:47:e0/00:00:e8:00:00/40 tag 7 ncq dma 4096 out
res 40/00:01:06:4f:c2/00:00:00:00:00/00 Emask 0x10 (ATA bus error)
[ +0.000741] ata2.00: status: { DRDY }
[ +0.000370] ata2: hard resetting link
[ +0.462912] ata2: SATA link up 6.0 Gbps (SStatus 133 SControl 300)
[ +0.003629] ata2.00: configured for UDMA/133
[ +0.016338] ata2: EH complete
And error repeats sporadically. After few errors kernel lower SATA link rate to 3.0 and after few more errors to 1.5.
06:00.0 SATA controller: Advanced Micro Devices, Inc. [AMD] FCH SATA Controller [AHCI mode] (rev 81) (prog-if 01 [AHCI 1.0])
Subsystem: Advanced Micro Devices, Inc. [AMD] FCH SATA Controller [AHCI mode]
Flags: bus master, fast devsel, latency 0, IRQ 36, IOMMU group 23
Memory at fcd01000 (32-bit, non-prefetchable) [size=2K]
Capabilities: [48] Vendor Specific Information: Len=08 >
Capabilities: [50] Power Management version 3
Capabilities: [64] Express Endpoint, MSI 00
Capabilities: [a0] MSI: Enable+ Count=1/2 Maskable- 64bit+
Capabilities: [d0] SATA HBA v1.0
Capabilities: [100] Vendor Specific Information: ID=0001 Rev=1 Len=010 >
Capabilities: [270] Secondary PCI Express
Capabilities: [2a0] Access Control Services
Capabilities: [400] Data Link Feature >
Capabilities: [410] Physical Layer 16.0 GT/s >
Capabilities: [440] Lane Margining at the Receiver >
Kernel driver in use: ahci
Kernel modules: ahci
06:00.1 SATA controller: Advanced Micro Devices, Inc. [AMD] FCH SATA Controller [AHCI mode] (rev 81) (prog-if 01 [AHCI 1.0])
Subsystem: Advanced Micro Devices, Inc. [AMD] FCH SATA Controller [AHCI mode]
Flags: bus master, fast devsel, latency 0, IRQ 38, IOMMU group 24
Memory at fcd00000 (32-bit, non-prefetchable) [size=2K]
Capabilities: [48] Vendor Specific Information: Len=08 >
Capabilities: [50] Power Management version 3
Capabilities: [64] Express Endpoint, MSI 00
Capabilities: [a0] MSI: Enable+ Count=2/2 Maskable- 64bit+
Capabilities: [d0] SATA HBA v1.0
Capabilities: [100] Vendor Specific Information: ID=0001 Rev=1 Len=010 >
Capabilities: [2a0] Access Control Services
Kernel driver in use: ahci
Kernel modules: ahci
Tested solution from [[https://myxp.dev.lightbridge.be/professionalXP/unaligned_write_command_sata_errors_on_linux_with_sepcific_hardware.html|Unaligned write command (SATA errors) on Linux (with specific hardware)]]
cat /sys/class/scsi_host/host*/link_power_management_policy
min_power_with_partial
min_power_with_partial
min_power_with_partial
echo max_performance | sudo tee /sys/class/scsi_host/host*/link_power_management_policy
KERNEL=="host[0-2]", SUBSYSTEM=="scsi_host", ATTR{link_power_management_policy}="max_performance"
* [[https://bugs.launchpad.net/ubuntu/+source/linux/+bug/539467|SATA link power management causes disk errors and corruption ]]
* [[https://www.systutorials.com/whats-wrong-with-the-messages-like-unrecovdata-10b8b-badcrc-and-failed-command-read-fpdma-queued-on-linux/|What’s wrong with the messages like “UnrecovData 10B8B BadCRC” and “failed command: READ FPDMA QUEUED” on Linux?]]
* [[https://review.coreboot.org/c/coreboot/+/40877|soc/intel/skl: always enable SataPwrOptEnable]]
* [[https://www.reddit.com/r/unRAID/comments/178oh7a/my_problems_with_the_seagate_exos_and_how_i_fixed/|My problems with the Seagate exos and how I fixed them]]
* [[https://forums.opensuse.org/t/samsung-ssd-840-evo-unrecovdata-10b8b-badcrc-error/104774|Samsung SSD 840 EVO “UnrecovData 10B8B BadCRC” error]]
===== increasing SATA link speed =====
After multiple reboots (without power off) ''ata2'' port works in 3.0 instead of 6.0:
kernel: ata3: SATA link up 6.0 Gbps (SStatus 133 SControl 300)
kernel: ata2: SATA link up 3.0 Gbps (SStatus 123 SControl 300)
It looks like SATA link speed is limited by HDD after previous failures.
To restore 6.0 link speed download [[https://github.com/Seagate/openSeaChest/releases|openSeaChest]]:
wget https://github.com/Seagate/openSeaChest/releases/download/test-ci_linux_tar_ownership/openseachest_24.10.15-dev_amd64.deb
dpkg -i openseachest_24.10.15-dev_amd64.deb
openSeaChest_Basics -d /dev/sda --phySpeed 3
readlink /sys/block/sda
../devices/pci0000:00/0000:00:08.2/0000:06:00.1/ata2/host1/target1:0:0/1:0:0:0/block/sda
echo 1 > /sys/block/sda/device/delete
echo "- - -" > /sys/class/scsi_host/host1/scan