[SOLVED] Re-install Proxmox

mellowism

New Member
Oct 30, 2021
5
0
1
40
Hi,

I am a fairly in-experienced Linux and Proxmox user, although I have had a Proxmox installation running for a couple of years, with different VM's and containers.
I have Proxmox installed on single 60 GB SSD drive, and I have all VM's on a 500 GB SSD, in the same machine.
Yesterday, my Proxmox installation failed to boot. Probably my SSD died.

I have now installed Proxmox 7 on a new 60 GB SSD I had lying around. The question is, how do I import all VM's and containers that are on my 500 GB drive that is still in my machine, and get them to show up as normal in Proxmox?

I have tried searching for import, mount and other posts and guides to no prevail. Any help or just to point me in the right direction would be helpful, since I think I just don't have the right terminology to find the correct instructions.

I can see the disk under Node-Disks:
1635602570230.png

Worth mentioning is that I also have all VM's backup on my TrueNAS, and I have added that back as an NFS, and all backups are there. I was thinking that perhaps the solution is to wipe the 500 GB SSD, and then restore VM's to that drive. But wanted to ask for help before I do any wipes.
 

Dunuin

Famous Member
Jun 30, 2020
7,317
1,767
149
Germany
Worth mentioning is that I also have all VM's backup on my TrueNAS, and I have added that back as an NFS, and all backups are there. I was thinking that perhaps the solution is to wipe the 500 GB SSD, and then restore VM's to that drive. But wanted to ask for help before I do any wipes.
That depends...
If you got recent backups of all VMs (and you wouldn't loose any important data) I would first verify that restoring a backup works. Then you can wipe that disk and restore your VMs (Vzdump Backups include VMs config + virtual disks) from that backup.

If there is stuff that wasn't backed up because your backup is too old you could make your old VMs running again. All the virtual disks are still on that VM storage you just need to add it as a VM storage again (Datacenter -> Storage -> Add -> TypeOfYourStorage). But what you have lost are the config files which were stored in /etc/pve/lxc and /etc/pve/qemu-server on your dead system SSD. Without config files your VMs wont work. You could unzip your backups, search for that config files in that backup and move them to your new Proxmox installation. In that case you wouldn'T need to wipe that disk to restore the individual VM. For the future it would make sense to additionally backup the "/etc" and especially the "/etc/pve/" folder too so you don'T need to setup stuff like firewall rules and so on from scratch.
 
Last edited:
  • Like
Reactions: mellowism

RobertusIT

Member
Jul 13, 2021
44
0
6
36
That depends...
If you got recent backups of all VMs (and you wouldn't loose any important data) I would first verify that restoring a backup works. Then you can wipe that disk and restore your VMs (Vzdump Backups include VMs config + virtual disks) from that backup.

If there is stuff that wasn't backed up because your backup is too old you could make your old VMs running again. All the virtual disks are still on that VM storage you just need to add it as a VM storage again (Datacenter -> Storage -> Add -> TypeOfYourStorage). But what you have lost are the config files which were stored in /etc/pve/lxc and /etc/pve/qemu-server on your dead system SSD. Without config files your VMs wont work. You could unzip your backups, search for that config files in that backup and move them to your new Proxmox installation. In that case you wouldn'T need to wipe that disk to restore the individual VM. For the future it would make sense to additionally backup the "/etc" and especially the "/etc/pve/" folder too so you don'T need to setup stuff like firewall rules and so on from scratch.
for the future, have sense:

backup of all lxc and vms, into an external drive.

But about host anc config/setup proxmox host, how can we backup it?
 

Dunuin

Famous Member
Jun 30, 2020
7,317
1,767
149
Germany
For the hosts config you can backup the "/etc" folder. If you want full backup of the hosts boot/system disk you can boot from a clonezilla USB stick and do a blocklevel backup of your complete system drives and safe it as an image to a NAS/external disk so that iamge could be wrote back to a new disk (inclusing bootloader and all that). IF you are using PBS you can also create a Linux Live Stick and use the PBS client to store these system disk images on your PBS. And you can use the PBS client on your PVE to backup your "/etc" folder too. That how I'm doing it right know. So PVE configs and PVE system disk images are stored on my PBS datastore and get deduplicated too.
 
  • Like
Reactions: mellowism

mellowism

New Member
Oct 30, 2021
5
0
1
40
Thanks for commenting and helping me, however I am still not sure how to proceed. The backup is only a day old, so I am leaning towards wiping the disk.
add it as a VM storage again (Datacenter -> Storage -> Add -> TypeOfYourStorage)
When I try to add this, I don't have any ZFS pool to choose from.
1635663873593.png

When I try to create a ZFS, it says "No unused disks". If I wipe the drive, will that become "unused" and available to be created as an ZFS, or do I need to do something else as well?

I moved the most crucial backup file from my NAS to my Windows computer, trying to extract that and access the files, but that put me in a deep hole, in trying to open a vma file on my Windows computer... I suppose that is not possible?
 

Dunuin

Famous Member
Jun 30, 2020
7,317
1,767
149
Germany
Thanks for commenting and helping me, however I am still not sure how to proceed. The backup is only a day old, so I am leaning towards wiping the disk.

When I try to add this, I don't have any ZFS pool to choose from.
View attachment 30990
After setting up your new PVE you need to import your old pool first (zpool import YourOldPoolsName). Then you can add that pool as a storage to PVE (type in the name of that pool in the "ZFS Pool" field).
When I try to create a ZFS, it says "No unused disks". If I wipe the drive, will that become "unused" and available to be created as an ZFS, or do I need to do something else as well?
Yes, PVE want a disk without partitions if you want to create a new ZFS pool with that disk. So you would need to wipe it first.

I moved the most crucial backup file from my NAS to my Windows computer, trying to extract that and access the files, but that put me in a deep hole, in trying to open a vma file on my Windows computer... I suppose that is not possible?
Look here how to extract VMA files: https://pve.proxmox.com/wiki/VMA
 
Last edited:
  • Like
Reactions: mellowism

mellowism

New Member
Oct 30, 2021
5
0
1
40
After setting up your new PVE you need to import your old pool first (zpool import YourOldPoolsName). Then you can add that pool as a storage to PVE (type in the name of that pool in the "ZFS Pool" field).
This is what I needed. I could now restore my most important VM, and access the files from WinSCP. The rest I will build up from scratch, and have a fun time doing so.
Look here how to extract VMA files: https://pve.proxmox.com/wiki/VMA
I suppose access a VMA file from windows is a no, then.

Thank you @Dunuin for your help. I really appreciate it.
 

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 your own in 60 seconds.

Buy now!