我正在尝试恢复意外格式化 ext4 分区后的内容。我从 Live USB 运行系统,并遵循本指南安装备份超级块。但是,当我尝试安装它时出现错误。这是我得到的:
ubuntu@ubuntu:/$ sudo dumpe2fs /dev/nvme0n1p4 | grep -i superblock
dumpe2fs 1.45.3 (14-Jul-2019)
Primary superblock at 0, Group descriptors at 1-31
Backup superblock at 32768, Group descriptors at 32769-32799
Backup superblock at 98304, Group descriptors at 98305-98335
Backup superblock at 163840, Group descriptors at 163841-163871
Backup superblock at 229376, Group descriptors at 229377-229407
Backup superblock at 294912, Group descriptors at 294913-294943
Backup superblock at 819200, Group descriptors at 819201-819231
Backup superblock at 884736, Group descriptors at 884737-884767
Backup superblock at 1605632, Group descriptors at 1605633-1605663
Backup superblock at 2654208, Group descriptors at 2654209-2654239
Backup superblock at 4096000, Group descriptors at 4096001-4096031
Backup superblock at 7962624, Group descriptors at 7962625-7962655
Backup superblock at 11239424, Group descriptors at 11239425-11239455
Backup superblock at 20480000, Group descriptors at 20480001-20480031
Backup superblock at 23887872, Group descriptors at 23887873-23887903
ubuntu@ubuntu:/$ sudo mount -o sb=32768 /dev/nvme0n1p4 /mnt
mount: /mnt: wrong fs type, bad option, bad superblock on /dev/nvme0n1p4, missing codepage or helper program, or other error.
ubuntu@ubuntu:/$ sudo mount -o sb=98304 /dev/nvme0n1p4 /mnt
mount: /mnt: wrong fs type, bad option, bad superblock on /dev/nvme0n1p4, missing codepage or helper program, or other error.
ubuntu@ubuntu:/$ sudo mount -o sb=23887872 /dev/nvme0n1p4 /mnt
mount: /mnt: wrong fs type, bad option, bad superblock on /dev/nvme0n1p4, missing codepage or helper program, or other error.
我在这里做错了什么?
答案1
如果可能的话,要做的第一件事就是将块设备“dd”复制到另一个设备。
然后,在设备上运行 e2fsck 以查看是否可以恢复文件系统。它会正常自动检查备份超级块位置。