Getting stuck on Emergency-Backup-Recovery

I’m trying to recover data from a Qubes Backup without the Qubes Restore function, i.e. I want to get into my backup information as if I were using a Linux machine, without Qubes.

I’m following the instructions on Emergency Backup Recovery, but I am stuck on step 1, the part where it says:

Now that you have the decrypted qubes.xml.000 file, search for the backup-path property inside of it. With the backup-path, extract only the files necessary for your VM (vmX).

[user@restore ~]$ tar -i -xvf qubes-backup-2015-06-05T123456 \
    backup-header backup-header.hmac vmX/

For me, I get an error (my target VM is called realestate):

user@restore-play:~$ tar -i -xvf qubes-backup-2023-05-10T164002 \ backup-header backup-header.hmac realestate/
tar:  backup-header: Not found in archive
tar: realestate: Not found in archive
tar: Exiting with failure status due to previous errors

I don’t understand

  • if the instructions say "search for the backup-path property " in qubes.xml.000, why do the terminal instructions not mention either backup-path or qubes.xml.000?
  • why doesn’t tar find backup-header? I am sure I am typing things correctly and previous steps worked okay - its already extracted a file name backup-header to the host directory in an earlier step.
  • why can’t tar find realestate? I know its in the archive!
  • (admission: I don’t understand all of the terminal commands, e.g. what does \ and / do here?)

Help gratefully received.

The \ character is only meant to be entered if the command is typed in as-is broken over two lines, in which case it bridges the two lines. If you’re typing in one line instead, omit that \ so as not to make the shell pass the subsequent space character to tar (which causes it to look for a file named <SPACE>backup-header).

And instead of the actual VM name like realestate there’s an anonymized vmN form that must be used, where N is some number like 123 which can be looked up in qubes.xml.

It’s a bit of a mess… There’s an ongoing effort by @adw and me to rewrite the instructions, maybe take a look at the bleeding edge version.


thanks for this. I’ll work through the “bleeding edge” version today.

Suggestion for instructions @rustybird : instruct us at the start to install xmlstarlet, (along with telling us to install scrypt).

1 Like

@rustybird Some notes offered here as feedback on the instructions you’re working on.

  • (as above) Include instructions to install xmlstarlet in same section as installing scrypt. Its not really an optional app, so deal with it first.

  • Step 2, [user@restore ~]$ read -r backup_pass
    Add: “Enter your passphrase at the prompt, then hit enter.”

  • Step 9, I don’t think the following line is very useful:

[user@restore ~]$ cat /mnt/img/home/user/your_data.txt

Arguably, its far more useful to the general user to showcase the image contents, so instead use:

[user@restore ~]$ ls /mnt/img/home/user/

Other than that, the instructions you have there are very useable and very important. Can you publish them to the Qubes website soon?

1 Like

Regards Step 2, That might better be
“Enter your passphrase at the prompt, (n.b. it will be in clear text), then hit enter.”

1 Like