help recovering a node and its VMs

spacebass

Active Member
Feb 25, 2019
13
0
41
46
Good evening friends,
Well... I did it. I did the worst thing and all the safeguards failed.
I did an rm -rf /var/lib/pve-cluster

Turns out my backup wasn't working :(

And the result is that when I finally recovered my system, none of my VMs exist. So I've been trying to rebuild by creating new VMs and associating the old VM drives.

BUT I think some of my VM drives are missing. Most everything was stored in a 'directory' which is a drive mounted at /m2

But some of my VMs aren't there. I thought perhaps they might be in /var/lib/vz but that director seems to have been recreated in the recovery process.

I discovered an LVM pool called PVE - admittedly I'm not too up on LVM. I see some drives there. But again, not sure I'm seeing everything.

Is there somewhere else where my .qcow2 files might be? Or were they in some blob in my ../pve-cluster ?
 
when I finally recovered my system,
how did you recover? did you reinstall from the iso? if yes, the disk where you installed pve to got wiped during install

I discovered an LVM pool called PVE - admittedly I'm not too up on LVM. I see some drives there. But again, not sure I'm seeing everything.
try to add the lvm / lvmthin as a storage and then do a 'qm rescan' and 'pct rescan'
this will search all defined storages for vm disk images (and add it to the relevant vms as 'unused')
 
how did you recover? did you reinstall from the iso? if yes, the disk where you installed pve to got wiped during install


try to add the lvm / lvmthin as a storage and then do a 'qm rescan' and 'pct rescan'
this will search all defined storages for vm disk images (and add it to the relevant vms as 'unused')

Thanks!
Looks like ‘qm rescan’ found some drives; trying to determine if they are the same ones I’d already found.

‘pct rescan’ doesn’t seem to be a valid command. I did a man on pct and didn’t see anything similar. I would love to recover those too. Any tips?

To recover my node:
I had to stop all services, then go into the sql lite DB and delete the corosync entries. Then I deleted /etc/corosync/*

Then I had to recreate the SSL keys and web certificates.

Then I got the web GUI back and could see my node.
 
Last edited:
‘pct rescan’ doesn’t seem to be a valid command. I did a man on pct and didn’t see anything similar. I would love to recover those too. Any tips?
should be a thing since pve-container version 2.0-31
 
Ah! ‘apt upgrade’ to the rescue. I’ve got pct rescan now, but it didn’t find anything.

I’m still missing a major cow qcow2 and tried finding by name. I’m not sure how, but it’s gone. I’m guessing it must have been in that pave-cluster directory?
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!