fsck检查lv分区:
#
# fsck /dev/db2_test
The current volume is: /dev/db2_test
fsck: 0507-020 Invalid magic number in the primary superblock.
fsck: 0507-013 Invalid magic number in the secondary superblock.
Primary superblock is corrupt.
Secondary superblock is corrupt.
fsck: 0507-018 Superblock is corrupt and cannot be repaired.
Both primary and secondary copies are corrupt. Cannot continue.
收起用dd 命令把第二个超级块修复第一个超级块,不成功 如下:
# dd count=1 bs=4k skip=31 seek=1 if=/dev/db2_test of=/dev/db2_test
1+0 records in.
1+0 records out.
#
# fsck /dev/db2_test 2>&1 |tee /tmp/fsck.errs
The current volume is: /dev/db2_test
fsck: 0507-020 Invalid magic number in the primary superblock.
fsck: 0507-013 Invalid magic number in the secondary superblock.
Primary superblock is corrupt.
Secondary superblock is corrupt.
fsck: 0507-018 Superblock is corrupt and cannot be repaired.
Both primary and secondary copies are corrupt. Cannot continue.
没有成功 看起来是没救了,用dd导出lv再进行数据恢可以吗?具体怎么操作?没弄过?
之前有过什么操作?这个文件系统是否重要?如果fsck不好用的话,基本就够呛了
收起修复没成功 查看了下超级块的magic number:
# od -x -N 64 /dev/db2_test +0x1000
0001000 0000 2000 0000 0000 0000 0000 0001 6000
0001010 0000 0100 0000 0008 0000 0055 0000 0004
0001020 05ff ffff ffff ffff ffff ffff ffff ffff
0001030 ffff ffff ffff ffff ffff ffff ffff ffff
0001040
# od -x -N 64 /dev/db2_test +0x1f000
001f000 0000 2000 0000 0000 0000 0000 0001 6000
001f010 0000 0100 0000 0008 0000 0055 0000 0004
001f020 05ff ffff ffff ffff ffff ffff ffff ffff
001f030 ffff ffff ffff ffff ffff ffff ffff ffff
001f040
#
收起