|
N100 all in one 主机,运行中突然断电,在上电后无法进入系统后,接其他linux 提取了系统硬盘镜像qcow2,其他PVE配置虚拟机系统后无法启动,磁盘崩溃了。尝试转换qcow2 格式为raw失败提示如下:
root@pve:/qemu-img convert vm-666-disk-0.qcow2 -O raw vm-666-disk-0.img
qcow2: Image is corrupt: Cluster allocation offset 0x3f8319e9c9e200 unaligned (L2 offset: 0x20050000, L2 index: 0x1); further non-fatal corruption events will be suppressed
qemu-img: error while reading block status at offset 536936448: Input/output error
因为虚拟机内部数据需要提取,现在解释方法:
1. 安装 apt install gddrescue -y
2. 执行如下命令:
root@pve:#modprobe nbd
root@pve:#qemu-nbd --connect=/dev/nbd0 vm-666-disk-0.qcow2
root@pve:#ddrescue /dev/nbd0 new_vm666.raw
等待运行结束。
3.分离磁盘镜像
root@pve:#qemu-nbd --disconnect /dev/nbd0
4. 复制new_vm666.raw到windows尝试使用DiskGenius 或者winhex 提取文件。
|
|