Several VMs/CTs Corrupt and Wont Start

Keefe

New Member
Sep 26, 2017
1
0
1
40
My server locked up and when I rebooted it Proxmox wouldn't load due to some file corruption errors. I ran fsck and now proxmox boots fine but several of the VMs/CTs wont start. When I run pct fsck on them i get the following:
root@proxmox-0:/var/lib/vz/images# pct fsck 115
fsck from util-linux 2.25.2
/var/lib/vz/images/115/vm-115-disk-1.raw contains a file system with errors, check forced.
/var/lib/vz/images/115/vm-115-disk-1.raw: Inode 9043981 has an invalid extent node (blk 36209363, lblk 0)


/var/lib/vz/images/115/vm-115-disk-1.raw: UNEXPECTED INCONSISTENCY; RUN fsck MANUALLY.
(i.e., without -a or -p options)
command 'fsck -a -l /var/lib/vz/images/115/vm-115-disk-1.raw' failed: exit code 4

How can i fix this?
 
My server locked up and when I rebooted it Proxmox wouldn't load due to some file corruption errors. I ran fsck and now proxmox boots fine but several of the VMs/CTs wont start. When I run pct fsck on them i get the following:
root@proxmox-0:/var/lib/vz/images# pct fsck 115
fsck from util-linux 2.25.2
/var/lib/vz/images/115/vm-115-disk-1.raw contains a file system with errors, check forced.
/var/lib/vz/images/115/vm-115-disk-1.raw: Inode 9043981 has an invalid extent node (blk 36209363, lblk 0)


/var/lib/vz/images/115/vm-115-disk-1.raw: UNEXPECTED INCONSISTENCY; RUN fsck MANUALLY.
(i.e., without -a or -p options)
command 'fsck -a -l /var/lib/vz/images/115/vm-115-disk-1.raw' failed: exit code 4

How can i fix this?


Since success of repair of the obviously damaged file systems at the virtual disks depends on the severity of damage it is not guaranteed. However, for attempting the usual repair methods with fsck (and maybe other utilities) mount the virtual disk(s) as loop device(s) for further investigation, e.g.

Code:
losetup /dev/loop0 /var/lib/vz/images/115/vm-115-disk-1.raw

and then

Code:
fsck.ext4 /dev/loop0

with the proper parameters offered by fsck.ext4 for repair.