* BTRFS won't mount in degraded mode
@ 2022-07-12 18:57 bobbygiraffe
0 siblings, 0 replies; only message in thread
From: bobbygiraffe @ 2022-07-12 18:57 UTC (permalink / raw)
To: linux-btrfs
I'm running a BTRFS filesystem with 8 devices. I believe the data was setup in RAID5 mode, and the metadata was RAID1. Each drive is encrypted with luks, and decrypted on boot with /etc/crypttab. Recently I had a drive fail and completely stop working, and the system stopped booting (presumably because /etc/crypttab was failing). When the drive finally arrived, I took out the broken one and connected the new one.
My intention was to mount the filesystem in degraded mode and then use btrfs replace to replace the old missing drive with the new drive. However, I've been unable to mount them.
Here's my setup:
uname -a
Linux bob 5.13.19-2-pve #1 SMP PVE 5.13.19-4 (Mon, 29 Nov 2021 12:10:09 +0100) x86_64 GNU/Linux
btrfs --version
btrfs-progs v5.10.1
btrfs fi show
bad tree block 30638080, bytenr mismatch, want=30638080, have=0
bad tree block 860242231296, bytenr mismatch, want=860242231296, have=0
ERROR: failed to read block groups: Input/output error
Label: 'BTRFS' uuid: 76ce90e7-8225-4a34-90e1-2d35e0f4e89a
Total devices 8 FS bytes used 26.80TiB
devid 2 size 3.64TiB used 3.06TiB path /dev/mapper/HDDC
devid 3 size 7.28TiB used 5.52TiB path /dev/mapper/HDDH
devid 4 size 7.28TiB used 6.32TiB path /dev/mapper/HDDF
devid 5 size 7.28TiB used 6.73TiB path /dev/mapper/HDDE
devid 6 size 3.57TiB used 519.00GiB path /dev/mapper/HDDJ
devid 7 size 3.64TiB used 593.06GiB path /dev/mapper/HDDG
devid 8 size 3.64TiB used 594.00GiB path /dev/mapper/HDDD
*** Some devices missing
The command I tried:
mount -t btrfs -o degraded /dev/mapper/HDDD /mnt/btrfs
Resulting in:
[ 306.632524] BTRFS info (device dm-15): flagging fs with big metadata feature
[ 306.632528] BTRFS info (device dm-15): allowing degraded mounts
[ 306.632530] BTRFS info (device dm-15): disk space caching is enabled
[ 306.632531] BTRFS info (device dm-15): has skinny extents
[ 306.658947] BTRFS warning (device dm-15): devid 1 uuid b3429c81-83cc-4401-8e18-a85d89e320fd is missing
[ 307.225260] BTRFS warning (device dm-15): failed to read root (objectid=9): -5
[ 307.232646] BTRFS error (device dm-15): open_ctree failed
I have also checked
btrfs rescue super-recover -v /dev/mapper/HDDD
All Devices:
Device: id = 7, name = /dev/mapper/HDDG
Device: id = 4, name = /dev/mapper/HDDF
Device: id = 5, name = /dev/mapper/HDDE
Device: id = 2, name = /dev/mapper/HDDC
Device: id = 3, name = /dev/mapper/HDDH
Device: id = 6, name = /dev/mapper/HDDJ
Device: id = 8, name = /dev/mapper/HDDD
Before Recovering:
[All good supers]:
device name = /dev/mapper/HDDG
superblock bytenr = 65536
device name = /dev/mapper/HDDG
superblock bytenr = 67108864
device name = /dev/mapper/HDDG
superblock bytenr = 274877906944
device name = /dev/mapper/HDDF
superblock bytenr = 65536
device name = /dev/mapper/HDDF
superblock bytenr = 67108864
device name = /dev/mapper/HDDF
superblock bytenr = 274877906944
device name = /dev/mapper/HDDE
superblock bytenr = 65536
device name = /dev/mapper/HDDE
superblock bytenr = 67108864
device name = /dev/mapper/HDDE
superblock bytenr = 274877906944
device name = /dev/mapper/HDDC
superblock bytenr = 65536
device name = /dev/mapper/HDDC
superblock bytenr = 67108864
device name = /dev/mapper/HDDC
superblock bytenr = 274877906944
device name = /dev/mapper/HDDH
superblock bytenr = 65536
device name = /dev/mapper/HDDH
superblock bytenr = 67108864
device name = /dev/mapper/HDDH
superblock bytenr = 274877906944
device name = /dev/mapper/HDDJ
superblock bytenr = 65536
device name = /dev/mapper/HDDJ
superblock bytenr = 67108864
device name = /dev/mapper/HDDJ
superblock bytenr = 274877906944
device name = /dev/mapper/HDDD
superblock bytenr = 65536
device name = /dev/mapper/HDDD
superblock bytenr = 67108864
device name = /dev/mapper/HDDD
superblock bytenr = 274877906944
[All bad supers]:
All supers are valid, no need to recover
Another thing I have tried is
btrfs rescue zero-log /dev/mapper/HDDD
bad tree block 30638080, bytenr mismatch, want=30638080, have=0
bad tree block 31965184, bytenr mismatch, want=31965184, have=0
ERROR: could not open ctree
Any ideas on what to try next would be appreciated.
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2022-07-12 19:22 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-12 18:57 BTRFS won't mount in degraded mode bobbygiraffe
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).