On 2019/7/30 下午9:57, Swâmi Petaramesh wrote:
> Hello,
>
> Le 30/07/2019 à 09:21, Qu Wenruo a écrit :
>> Unfortunately, transid error here helps nothing.
>
> Now, each and everytime I try to mount this disk on the original
> machine, or another one, I get :
When the message shows, it means the damage is already done *BEFORE*.
Really nothing to do with your current kernel version.
If it's the fault of btrfs or device mapper, then it's related to the
kernel used in last unmount (if unmounted cleanly) or last unclean
shutdown before hitting this error.
If it's the hardware, you'd check if your disk has unreliable flush/fua
behavior, then different kernel may have some difference in how it's
affected, but nothing can save you.
>
> systemd[1]: run-media-xxxxxxxxxxxxxxxx.mount: Succeeded.
> kernel: BTRFS info (device dm-2): disk space caching is enabled
> kernel: BTRFS info (device dm-2): has skinny extents
> kernel: BTRFS error (device dm-2): parent transid verify failed on
> 2137144377344 wanted 7684 found 7499
> kernel: BTRFS error (device dm-2): parent transid verify failed on
> 2137144377344 wanted 7684 found 7499
> kernel: BTRFS error (device dm-2): parent transid verify failed on
> 2137144377344 wanted 7684 found 7499
> kernel: BTRFS: error (device dm-2) in btrfs_drop_snapshot:9465: errno=-5
> IO failure
> kernel: BTRFS info (device dm-2): forced readonly
>
> (It first appears to mount OK, then the errors follow a few seconds
> afterwards, and the it remounts readonly).
>
> The "7499" displays seems to correspond to the most recent snapshot
> created on the disk (using btrfs su li).
>
> Is there any way I could repair this several-TB FS, ever if it implies
> losing the latest (or a few of the latest) created subvols and snapshots ?
Short answer: no.
If you want to recover to a rw mountable fs and pass btrfs check, the
chance is very low, as the corruption happens in extent tree, an
essential tree to write operations.
Corruption there is not easy to repair to pass btrfs check again.
Thanks,
Qu
>
> TIA.
>
> Kind regards.
>