View previous topic :: View next topic |
Author |
Message |
Dro021 n00b

Joined: 18 Jun 2024 Posts: 5
|
Posted: Sun Mar 23, 2025 7:49 am Post subject: Btrfs fail to mount |
|
|
Hello,
Recently i was backing up some data to a btrfs external hdd. After some transfer of data with an rsync command, i got an 'input/output' error on the directory
my drive was mounted to... Weird i thought to myself, and unmounted the drive without any warning this time. When i try to plug it back it i can't mount this drive
in any way.
This is the output of dmesg command
Code: |
[44861.502129] BTRFS: device fsid 744fff59-2a4f-49f1-a0c4-9a7b6acc40e8 devid 1 transid 49 /dev/sdc1 (8:33) scanned by mount (13105)
[44861.503768] BTRFS info (device sdc1): first mount of filesystem 744fff59-2a4f-49f1-a0c4-9a7b6acc40e8
[44861.503786] BTRFS info (device sdc1): using crc32c (crc32c-intel) checksum algorithm
[44861.503791] BTRFS info (device sdc1): using free-space-tree
[44861.535878] BTRFS error (device sdc1): level verify failed on logical 30408704 mirror 1 wanted 1 found 0
[44861.549271] BTRFS error (device sdc1): level verify failed on logical 30408704 mirror 2 wanted 1 found 0
[44861.549319] BTRFS error (device sdc1): failed to load root extent
[44861.550025] BTRFS error (device sdc1): open_ctree failed: -5
|
i tried differents PCs and got the same result even though they are not on the same distribution and regardless of what btrfs-progs version i am using.
I searched online but nothing worked, I noticed something wrong though, while trying to run the command Code: | btrfsck --init-extent-tree | i get a segmentation fault this is the full output of the command https://bpa.st/LDFA
this is the output of Code: | smartctl -a /dev/sdc1 | https://bpa.st/IY2Q
Is my drive dead ? smartctl does not seem to think so..
Is there a way i can recover my data ?
Thanks |
|
Back to top |
|
 |
dE_logics Advocate


Joined: 02 Jan 2009 Posts: 2335 Location: $TERM
|
Posted: Sun Mar 23, 2025 10:02 am Post subject: |
|
|
All i can say is that btrfs is not in good state it seems. Good thing I switched to xfs.
You may try to build sys-fs/btrfs-progs with safe cflags and then retry the fsck.
Also isn't this just a backup? So you can always retry. _________________ My blog |
|
Back to top |
|
 |
Zucca Moderator


Joined: 14 Jun 2007 Posts: 4001 Location: Rasi, Finland
|
Posted: Sun Mar 23, 2025 4:29 pm Post subject: |
|
|
You should run the extended (full) smart test on the drive and then check the smart values. _________________ ..: Zucca :..
My gentoo installs: | init=/sbin/openrc-init
-systemd -logind -elogind seatd |
Quote: | I am NaN! I am a man! |
|
|
Back to top |
|
 |
Dro021 n00b

Joined: 18 Jun 2024 Posts: 5
|
Posted: Fri Mar 28, 2025 6:08 am Post subject: |
|
|
Zucca wrote: | You should run the extended (full) smart test on the drive and then check the smart values. |
I went and reformated my disk after the smart command failed saying tests could not be performed. I also tried to make an image of my disk with the dd command but after some time it abruptly stops with a segfault.
The good news is that after the reformat the disk was able to be mounted. The most likely explanation of my problem was that i mounted this disk before without passing the "-o compress=zstd,subvol=@root" option and ended up writting to it without compression and subvolume.
I'll be more careful with my backup in the future as there was data on this disk that was not elsewhere.
Thank for the help really apreaciate it, and sorry for the late answer.
Have a nice day |
|
Back to top |
|
 |
Hu Administrator

Joined: 06 Mar 2007 Posts: 23273
|
Posted: Fri Mar 28, 2025 1:52 pm Post subject: |
|
|
Something seems wrong here. SMART is a low-level operation that works without regard to what, if any, filesystem is on the device. Therefore, no matter how badly you may have corrupted the filesystem, SMART should still be able to trigger the drive's self-tests and access its logs. I suggest that you perform the full test that Zucca suggested above.
It is very strange for dd to exit with a segmentation fault. |
|
Back to top |
|
 |
logrusx Advocate


Joined: 22 Feb 2018 Posts: 2874
|
Posted: Fri Mar 28, 2025 2:11 pm Post subject: |
|
|
Code: | SMART support is: Available - device has SMART capability.
SMART support is: Disabled |
Available but disabled. Your drive might not have gone but cables/ports might be damaged. If both ports on the enclosure and on the computer look good visually and the cable is not loose and doesn't shake when you plug it in, try with a different cable. Also check dmesg for hardware errors. Also try with a different port on the computer.
This is a 2.5'' HDD in an enclosure, you can disassemble the enclosure and mount the HDD on a proper SATA cable in a desktop computer.
Best Regards,
Georgi |
|
Back to top |
|
 |
|