3 months ago, after a powercut, our Synology NAS DS415+ started to reboot to hell, staying 5 minutes up and then rebooting. We recently tried to recover the data from it,2*3TB SHR-RAID 1.
After a long way through Synology Documentation, I mounted the raid without any problem, and when I run a classic ls
in the folder, I have the following error:
ls: cannot access '/mnt/FOLDERA': Input/output error
FOLDERA
FOLDERB
I tried to run ls /mnt/FOLDERA
and I have the same io error.
I also tried on folderB and I have no problem to access to this folder.
I tried also to mount the disk without the raid, and the same problem comes on both disks. Looking at dmesg, every time I try accessing any io error folder, I have the following logs:
[109433.244496] BTRFS error (device dm-0): block=133562368 read time tree block corruption detected
[109433.301567] BTRFS critical (device dm-0): corrupt leaf: root=1 block=133070848 slot=30, invalid root flags, have 0x200000000 expect mask 0x1000000000001
[109433.301575] BTRFS error (device dm-0): block=133070848 read time tree block corruption detected
[109433.301876] BTRFS critical (device dm-0): corrupt leaf: root=1 block=133070848 slot=30, invalid root flags, have 0x200000000 expect mask 0x1000000000001
[109433.301883] BTRFS error (device dm-0): block=133070848 read time tree block corruption detected
[109441.972111] BTRFS critical (device dm-0): corrupt leaf: root=1 block=132923392 slot=17, invalid root flags, have 0x200000000 expect mask 0x1000000000001
[109441.972121] BTRFS error (device dm-0): block=132923392 read time tree block corruption detected
[109441.972356] BTRFS critical (device dm-0): corrupt leaf: root=1 block=132923392 slot=17, invalid root flags, have 0x200000000 expect mask 0x1000000000001
[109441.972362] BTRFS error (device dm-0): block=132923392 read time tree block corruption detected
[109449.284056] BTRFS critical (device dm-0): corrupt leaf: root=1 block=132923392 slot=17, invalid root flags, have 0x200000000 expect mask 0x1000000000001
[109449.284066] BTRFS error (device dm-0): block=132923392 read time tree block corruption detected
[109449.284318] BTRFS critical (device dm-0): corrupt leaf: root=1 block=132923392 slot=17, invalid root flags, have 0x200000000 expect mask 0x1000000000001
[109449.284323] BTRFS error (device dm-0): block=132923392 read time tree block corruption detected
So my problem seems to be with btrFS, so I tried a scrub
UUID: f9995e41-6f97-41e8-bf0a-31f83c9e8314
Scrub started: Wed Aug 5 08:53:01 2020
Status: finished
Duration: 3:10:00
Total to scrub: 1.20TiB
Rate: 110.51MiB/s
Error summary: no errors found
And also a recover but Seems to not being able to find the root block.
btrfs-find-root /dev/vg1000/lv
Superblock thinks the generation is 3391864
Superblock thinks the level is 1
Found tree root at 656900096 gen 3391864 level 1
Well block 642072576(gen: 3391863 level: 1) seems good, but generation/level doesn't match, want gen: 3391864 level: 1
Well block 341000192(gen: 3391845 level: 0) seems good, but generation/level doesn't match, want gen: 3391864 level: 1
Well block 299876352(gen: 3391844 level: 1) seems good, but generation/level doesn't match, want gen: 3391864 level: 1
Well block 190988288(gen: 3391842 level: 0) seems good, but generation/level doesn't match, want gen: 3391864 level: 1
Well block 159334400(gen: 3391841 level: 1) seems good, but generation/level doesn't match, want gen: 3391864 level: 1
Well block 88440832(gen: 3391840 level: 1) seems good, but generation/level doesn't match, want gen: 3391864 level: 1
........................................... ~50 lines ...
Well block 4243456(gen: 3 level: 0) seems good, but generation/level doesn't match, want gen: 3391864 level: 1
Well block 4194304(gen: 2 level: 0) seems good, but generation/level doesn't match, want gen: 3391864 level: 1
The only thing I didn't try is the btrfs check as it seems to be a very dangerous command.
How can I mount all my data to make it accessible? I currently run on a ubuntu 20.04 live-usb key to be able to mount the disk in the machine.
sudo smartctl -A -H /dev/sda
(use your two disks) and ofbtrfs device stats /mnt
.