Upgrade went very wrong need to recover VMs

Brawndo

New Member
Apr 25, 2024
4
2
3
I went through the process to upgrade from 7.4 to 8, in trying to get the pve7to8 tool onto my machine I appear to have corrupted the install so badly that when trying to boot it goes through bios and then has a black screen. No errors or anything.

I can see from a recovery image that the Hard drives are still formatted and can see the VM Disk partitions and can also see the VM Config Files in the root partition.

I have 2 other Proxmox boxes. Is it possible to attach the two Hard drives from my corrupted install and register them as storage to an empty proxmox install I have to recover certain files?
 
I went through the process to upgrade from 7.4 to 8, in trying to get the pve7to8 tool onto my machine I appear to have corrupted the install so badly that when trying to boot it goes through bios and then has a black screen. No errors or anything.
Is your machine reachable via network despite you don't see anything? Not seeing anything may be "just" a display problem.

I can see from a recovery image that the Hard drives are still formatted and can see the VM Disk partitions and can also see the VM Config Files in the root partition.
You can extract everything you want from the recovery image.

I have 2 other Proxmox boxes. Is it possible to attach the two Hard drives from my corrupted install and register them as storage to an empty proxmox install I have to recover certain files?
Depending on the used storage this may work, it will not work if you have ZFS on both with its default name rpool or with LVM and the same default name pve.
 
Is your machine reachable via network despite you don't see anything? Not seeing anything may be "just" a display problem.
Nope, no SSH or anything, router can't see it.

You can extract everything you want from the recovery image.
I've got one downloaded and I'll have a look.

Depending on the used storage this may work, it will not work if you have ZFS on both with its default name rpool or with LVM and the same default name pve.
I know that the different drives for the VM Disks were LVMs, the other two Proxmox boxes are set up the same, before i rebooted and lost complete access none of the VM HDDs were mounted, how do I remount them the other side? As when i tried a standard mount command it wouldn't let me do it, though I can't remember the error.

Can I physically remove the HDDs from the old box and add them into another PRoxmox host and get it to recognize the partitions with the VM Disks on?

I don't need to recover the VMs per say, I more need some files out of some Docker volumes on the Machines.
 
I popped in a different hard drive and installed Proxmox on it, I can see the old Hard drive (ignore the thumb drive).
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
sda 8:0 0 931.5G 0 disk
├─sda1 8:1 0 1007K 0 part
├─sda2 8:2 0 1G 0 part /boot/efi
└─sda3 8:3 0 930.5G 0 part
├─pve-swap 252:4 0 8G 0 lvm [SWAP]
├─pve-root 252:5 0 96G 0 lvm /
├─pve-data_tmeta 252:6 0 8.1G 0 lvm
│ └─pve-data 252:8 0 794.3G 0 lvm
└─pve-data_tdata 252:7 0 794.3G 0 lvm
└─pve-data 252:8 0 794.3G 0 lvm
sdb 8:16 1 1.9G 0 disk
├─sdb1 8:17 1 240K 0 part
├─sdb2 8:18 1 8M 0 part
├─sdb3 8:19 1 1.3G 0 part
└─sdb4 8:20 1 300K 0 part
nvme0n1 259:0 0 476.9G 0 disk
├─nvme0n1p1 259:1 0 1007K 0 part
├─nvme0n1p2 259:2 0 1G 0 part
└─nvme0n1p3 259:3 0 475.9G 0 part
├─pve--OLD--D810AC9B-swap 252:0 0 8G 0 lvm
├─pve--OLD--D810AC9B-root 252:1 0 96G 0 lvm
├─pve--OLD--D810AC9B-data_tmeta 252:2 0 3.6G 0 lvm
│ └─pve--OLD--D810AC9B-data-tpool 252:9 0 348.8G 0 lvm
│ ├─pve--OLD--D810AC9B-data 252:10 0 348.8G 1 lvm
│ ├─pve--OLD--D810AC9B-vm--100--disk--0 252:11 0 20G 0 lvm
│ ├─pve--OLD--D810AC9B-vm--101--disk--0 252:12 0 30G 0 lvm
│ ├─pve--OLD--D810AC9B-vm--101--disk--1 252:13 0 80G 0 lvm
│ ├─pve--OLD--D810AC9B-vm--102--disk--0 252:14 0 20G 0 lvm
│ ├─pve--OLD--D810AC9B-vm--102--disk--1 252:15 0 10G 0 lvm
│ ├─pve--OLD--D810AC9B-vm--103--disk--0 252:16 0 20G 0 lvm
│ ├─pve--OLD--D810AC9B-vm--103--disk--1 252:17 0 10G 0 lvm
│ ├─pve--OLD--D810AC9B-vm--104--disk--0 252:18 0 100G 0 lvm
│ ├─pve--OLD--D810AC9B-vm--104--disk--1 252:19 0 80G 0 lvm
│ └─pve--OLD--D810AC9B-vm--104--disk--2 252:20 0 100G 0 lvm
└─pve--OLD--D810AC9B-data_tdata 252:3 0 348.8G 0 lvm
└─pve--OLD--D810AC9B-data-tpool 252:9 0 348.8G 0 lvm
├─pve--OLD--D810AC9B-data 252:10 0 348.8G 1 lvm
├─pve--OLD--D810AC9B-vm--100--disk--0 252:11 0 20G 0 lvm
├─pve--OLD--D810AC9B-vm--101--disk--0 252:12 0 30G 0 lvm
├─pve--OLD--D810AC9B-vm--101--disk--1 252:13 0 80G 0 lvm
├─pve--OLD--D810AC9B-vm--102--disk--0 252:14 0 20G 0 lvm
├─pve--OLD--D810AC9B-vm--102--disk--1 252:15 0 10G 0 lvm
├─pve--OLD--D810AC9B-vm--103--disk--0 252:16 0 20G 0 lvm
├─pve--OLD--D810AC9B-vm--103--disk--1 252:17 0 10G 0 lvm
├─pve--OLD--D810AC9B-vm--104--disk--0 252:18 0 100G 0 lvm
├─pve--OLD--D810AC9B-vm--104--disk--1 252:19 0 80G 0 lvm
└─pve--OLD--D810AC9B-vm--104--disk--2 252:20 0 100G 0 lvm

But when I try mount (after getting the full path from lvdisplay I'm getting

mount: /mnt/1: wrong fs type, bad option, bad superblock on /dev/mapper/pve--OLD--D810AC9B-vm--104--disk--1, missing codepage or helper program, or other error.
dmesg(1) may have more information after failed mount system call.

 
I was actually about to respond to this thread to say I've basically fixed it.

I added the old storage as LVM-Thin under Datacentre -> storage

I then created a new VM on the extra install of proxmox.

Went into the config file for it in /etc/pve/qemu-server and started mounting the drives in here directly e.g:

scsi1: oD3YJx-4MGD-3Kce-oIMR-Nhv1-Lagu-CQp4BP:vm-100-disk-0,iothread=1,size=20G

Then started up the VM and ran a normal mount command, grabbed the data I needed, hard stopped the VM (shut down didn't work) then added the next drive in the file and turned it back on, rinse repeat.

The reason I did it this way rather than mounting all 10 drives is because the LVMs in them had similar names and I believe wouldn't have shown properly.

Suffice to say I have retrieved the data I needed, just thought I'd put this here in case someone had the same issue.
 

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!