Non-working Qubes Recovery (no backups)

Hi,
I have a colleague with an EFI Qubes 4.0 installation on a ThinkPad with a mainboard failure. The SATA SSD is working fine but his encrypted external disk used for his backups is corrupted & so has no backups. I have tried booting it another older ThinkPad (T450s) but it is not capable of booting Qubes 4 on EFI & I don’t have any other laptops with SATA drive ports, only NVMe.

Is there any method to either manually transfer the existing VMs or .imgs to another Qubes installation or better still - manually make a Qubes backup of the existing VMs to restore via Qubes Backup on another installation? I have my own working Qubes installation - but it is Qubes 4.1 & other Fedora laptops - & can attach the SSD externally to them.

Take a look at this, it could help:

I did have a look at that - but it seems to be about recovering existing Qubes backups & then mounting the image to extract data. We don’t have existing backups.

I could mount the existing private.img files I suppose - but I wanted to know if it was possible to actually restore/transfer the VMs on a new Qubes installation.

There probably is a way bit it is likely non-trivial. Maybe you could create a qube with the same name and then move the private volume to dom0 (I don’t know where specifically - maybe lookup something like “importing lvm volume”) and then replace the “fresh” volume with the one you had.

Or maybe get some inspiration from these instructions (the bottom part, specifically)

Some other documentation that could help:

edit: I’ve slightly adjusted the title for clarity. Feel free to adjust it if you feel it does not completely reflect this situation.

You can recover in this situation. Frankly, with no backups I would
image the disk you do have and work on the image. That way you can be
sure that you are not going to corrupt what you have.
If you cant do this, only mount the old disk ro.

I assume from “private.img” that you have Qubes installed using file
driver, and image files are stored under /var/lib/qubes.
If this is the case, install Qubes on a new disk, attach the old disk,
decrypt the Qubes partition and mount it.
In the new Qubes, create (e.g) “new”, and then copy the private.img
file from /mnt/var/lib/appvms/new/private.img to
/var/lib/appvms/new/private.img.
In most cases this will just work™. If you have increased the private
storage, try to do this in the new qube too.

That’s the principle - once you’ve tested it on a (non-networked) qube,
you can start batch copying.
The pain here is having to reproduce the setup on the new Qubes system
before running the transfer.
You could try copying qubes.xml from old to new - I’ve never tried it
and have no idea if it would work: my guess is that you would be hacking
about on that file for a long time.

1 Like