“缓存和超级代不匹配,空间缓存失效”是什么意思,如何修复?

Bra*_*iam 5 btrfs

我在尝试在我的系统中增加 btrfs 分区时遇到了一个小问题,即:

sudo btrfsck /dev/sdb9 
[sudo] password for braiam: 
Checking filesystem on /dev/sdb9
UUID: f7e9ac38-5068-4c55-97ab-41430b360d4f
checking extents
checking free space cache
cache and super generation don't match, space cache will be invalidated
checking fs roots
checking csums
There are no extents for csum range 0-69632
Csum exists for 0-69632 but there is no extent record
found 10204750230 bytes used err is 1
total csum bytes: 10835824
total tree bytes: 80138240
total fs tree bytes: 59863040
total extent tree bytes: 4743168
btree space waste bytes: 21830024
file data blocks allocated: 11097911296
 referenced 11097911296
Btrfs v3.16
Run Code Online (Sandbox Code Playgroud)

我正在尝试修复它。可悲的是,添加该检查的补丁(顺便说一句,如果失败,它将返回退出代码 1)并没有解释它是什么,也没有解释我们如何修复它。现在,分区有七大奇迹,但我无法调整它的大小。有什么方法可以解决这个问题并防止它在未来再次发生?

小智 4

btrfs 列表上有一篇文章建议使用该--clear-space-cache选项。以下命令为我解决了同样的问题:

btrfs check --clear-space-cache v1 /dev/sda5