Description
I am experiencing recurring btrfs filesystem corruption on my fedora installation, this has been going on for years now, i tried fixing it, failed not that long ago and had to reinstall fedora, so im being somewhat more careful now.
Of course, tried to help myself using chatgpt and google, i dont want to rush a btrfs check --repair though so im describing everything i can think of here and seeking the help of this forum.
In trying to fix this issue the last time it happened (there were other things but it was too long ago and before reinstalling fedora):
- Switched drives from a Samsung 970 to this Samsung 990 PRO, the same thing kept happening on the old one so that feels like a waste of money now but whatever.
In trying to fix the issue the CURRENT time:
-
Updated bios to the newest version
-
Tested memory but couldnt get memtest86+ to work so only with a memtester (sudo memtester 8GB 5) on a fedora live usb im using to debug this. Didnt get any errors for that but i know it probably wasnt thorough enough
-
Ran a btrfs check --readonly, results further down
Hardware information
-
Motherboard: ASRock A520M-HDV
-
BIOS: AMI P3.00, dated 2023-06-29 (this was updated into P4.10 after this info was collected)
-
CPU: AMD Ryzen 5 4500
-
RAM: 16 GB DDR4, 2 × 8 GB G.Skill F4-3200C16-8GIS
-
RAM speed reported by BIOS: DDR4-3200
-
Storage: Samsung SSD 990 PRO 2TB NVMe
-
SSD firmware: 8B2QJXD7
-
Affected partition:
/dev/nvme0n1p3 -
Btrfs filesystem UUID:
73b0efc1-1bbf-44a9-b61c-f4b8936608ae
Btrfs output
liveuser@localhost-live:~$ sudo btrfs check --readonly /dev/nvme0n1p3
Opening filesystem to check...
Checking filesystem on /dev/nvme0n1p3
UUID: 73b0efc1-1bbf-44a9-b61c-f4b8936608ae
[1/8] checking log skipped (none written)
[2/8] checking root items
[3/8] checking extents
data extent[3068469248, 4096] referencer count mismatch (root 257 owner 3844574 offset 382279680) wanted 0 have 1
data extent[3068469248, 4096] bytenr mimsmatch, extent item bytenr 3068469248 file item bytenr 0
data extent[3068469248, 4096] referencer count mismatch (root 257 owner 3844574 offset 382541824) wanted 1 have 0
backpointer mismatch on [3068469248 4096]
ERROR: errors found in extent allocation tree or chunk allocation
[4/8] checking free space tree
[5/8] checking fs roots
[6/8] checking only csums items (without verifying data)
[7/8] checking root refs
[8/8] checking quota groups skipped (not enabled on this FS)
found 851404390400 bytes used, error(s) found
total csum bytes: 828557228
total tree bytes: 2640494592
total fs tree bytes: 1551499264
total extent tree bytes: 167936000
btree space waste bytes: 398250390
file data blocks allocated: 10191907336192
referenced 895043592192
NVME health check
liveuser@localhost-live:~$ sudo smartctl -x /dev/nvme0
smartctl 7.5 2025-04-30 r5714 [x86_64-linux-6.19.10-300.fc44.x86_64] (local build)
Copyright (C) 2002-25, Bruce Allen, Christian Franke, www.smartmontools.org
=== START OF INFORMATION SECTION ===
Model Number: Samsung SSD 990 PRO 2TB
Serial Number: S7HENU0YB68490A
Firmware Version: 8B2QJXD7
PCI Vendor/Subsystem ID: 0x144d
IEEE OUI Identifier: 0x002538
Total NVM Capacity: 2,000,398,934,016 [2.00 TB]
Unallocated NVM Capacity: 0
Controller ID: 1
NVMe Version: 2.0
Number of Namespaces: 1
Namespace 1 Size/Capacity: 2,000,398,934,016 [2.00 TB]
Namespace 1 Utilization: 858,491,072,512 [858 GB]
Namespace 1 Formatted LBA Size: 512
Namespace 1 IEEE EUI-64: 002538 4b51a17d6a
Local Time is: Tue Oct 27 19:04:10 2026 UTC
Firmware Updates (0x16): 3 Slots, no Reset required
Optional Admin Commands (0x0017): Security Format Frmw_DL Self_Test
Optional NVM Commands (0x0055): Comp DS_Mngmt Sav/Sel_Feat Timestmp
Log Page Attributes (0x2f): S/H_per_NS Cmd_Eff_Lg Ext_Get_Lg Telmtry_Lg Log0_FISE_MI
Maximum Data Transfer Size: 512 Pages
Warning Comp. Temp. Threshold: 82 Celsius
Critical Comp. Temp. Threshold: 85 Celsius
Supported Power States
St Op Max Active Idle RL RT WL WT Ent_Lat Ex_Lat
0 + 9.61W - - 0 0 0 0 0 0
1 + 9.61W - - 1 1 1 1 0 0
2 + 9.61W - - 2 2 2 2 0 0
3 - 0.0500W - - 3 3 3 3 4200 3500
4 - 0.0050W - - 4 4 4 4 2200 22200
Supported LBA Sizes (NSID 0x1)
Id Fmt Data Metadt Rel_Perf
0 + 512 0 0
=== START OF SMART DATA SECTION ===
SMART overall-health self-assessment test result: PASSED
SMART/Health Information (NVMe Log 0x02, NSID 0xffffffff)
Critical Warning: 0x00
Temperature: 40 Celsius
Available Spare: 100%
Available Spare Threshold: 10%
Percentage Used: 0%
Data Units Read: 890,091 [455 GB]
Data Units Written: 2,751,457 [1.40 TB]
Host Read Commands: 5,126,025
Host Write Commands: 68,607,810
Controller Busy Time: 53
Power Cycles: 20
Power On Hours: 39
Unsafe Shutdowns: 4
Media and Data Integrity Errors: 0
Error Information Log Entries: 0
Warning Comp. Temperature Time: 2
Critical Comp. Temperature Time: 0
Temperature Sensor 1: 40 Celsius
Temperature Sensor 2: 45 Celsius
Thermal Temp. 1 Transition Count: 2
Thermal Temp. 2 Transition Count: 1
Thermal Temp. 1 Total Time: 9
Thermal Temp. 2 Total Time: 146
Error Information (NVMe Log 0x01, 16 of 64 entries)
No Errors Logged
Self-test Log (NVMe Log 0x06, NSID 0xffffffff)
Self-test status: No self-test in progress
No Self-tests Logged
liveuser@localhost-live:~$ sudo nvme smart-log /dev/nvme0
Smart Log for NVME device:nvme0 namespace-id:ffffffff
critical_warning : 0
temperature : 40 °C (313 K, 104 °F)
available_spare : 100%
available_spare_threshold : 10%
percentage_used : 0%
endurance group critical warning summary: 0
Data Units Read : 890091 (455.73 GB)
Data Units Written : 2751457 (1.41 TB)
host_read_commands : 5126025
host_write_commands : 68607810
controller_busy_time : 53
power_cycles : 20
power_on_hours : 39
unsafe_shutdowns : 4
media_errors : 0
num_err_log_entries : 0
Warning Temperature Time : 2
Critical Composite Temperature Time : 0
Temperature Sensor 1 : 40 °C (313 K, 104 °F)
Temperature Sensor 2 : 46 °C (319 K, 114 °F)
Thermal Management T1 Trans Count : 2
Thermal Management T2 Trans Count : 1
Thermal Management T1 Total Time : 9
Thermal Management T2 Total Time : 146
Right as it happened
I have some pictures i took of the journalctl output right after this particular read-only switch, sorry theyre not transcribed into text:
Help me
-
My first priority is making this stop in the future, if the solution is getting new RAM sticks, i will buy some, please help with that.
-
My second priority is getting back on my install safely quickly, i do have backups of the data on there quickly, the best such backup is actually the old nvme that i cloned into this new one. Either way, i have schoolwork and this is my main pc so i’d like to know if its safe to run a btrfs check --repair and get back to work.


