Add disk with VMs back to ProxMox GUI

Altremo

Member
May 16, 2021
6
1
8
29
Good day.

I've encountered a critical failure of one of my drives with PorxMox on it. However, my second drive is just fine and had all VMs on it. After re-installing ProxMox to a new drive, I cannot really figure out how can I add my second drive back. I have tried to follow a guide in this thread -> (https://forum.proxmox.com/threads/how-to-mount-existing-disk-to-storage.66559/), however, it says that drive already mounted and I see nothing. Maybe I am doing something wrong? Any help will be appreciated.
 
"Datacenter -> Storage -> Add" is the correct way to add disks with existing data. But are you sure you used LVM and not for example LVM-Thin to store your virtual disks?
Also keep in mind that a VM storage won't store the whole VM. It only stores the virtual disks. All VM configs were stored on the PVE system disk you have lost. So you won't see any VMs in PVE, even with that old disk added.
In case you didn't created a backup of your VMs or the /etc/pve folder, all you can do is creating new VMs from scratch and then adding your existing virtual disks to those new VMs and hope they will boot.
 
Last edited:
"Datacenter -> Storage -> Add" is the correct way to add disks with existing data. But are you sure you used LVM and not for example LVM-Thin to store your virtual disks?
Also keep in mind that a VM storage won't store the whole VM. It only stores the virtual disks. All VM configs were stored on the PVE system disk you have lost. So you won't see any VMs in PVE, even with that old disk added.
In case you didn't created a backup of your VMs or the /etc/pve folder, all you can do is creating new VMs from scratch and then adding your existing virtual disks to those new VMs and hope they will boot.
Thank you for your reply! How can I add existing virtual disks to new VMs?
 
You would have to rename them to match the VMID and a free disk number. Then run a qm rescan and they should show up as an unatached disk in the VMs hardware tab. You can then edit these unattached disks to add them to the VM.

And for the next time set up a backup job that automatically writes backups to an NAS or dedicated backup disk. And a cron that tar-gzips your "/etc" folder.
 
Last edited:
  • Like
Reactions: Altremo