> upgrading from 3.1 to 3.2 broke with several hundred dupe packages. 
> package-cleanup didn't work, so I had to remove dupes by hand one by one.
>
> clicking through many y/N questions, I inadvertently removed libxml dupe, 
> which in turn removed qubes-core-dom0, all templates, and borked my system.
>
> I'm hurting here. Is there any way to restore my Qubes to a working system?
>
> No backups. (of course.)
>
> Any suggestions for system recovery?
>
> Or at least recovering my data?
I can only give some limited backup help (from memory, I did it some
moment ago). Use a live linux WITH luks support (tails is great). Boot
it (in tails activate root at startup!), open terminal, enter sudo su -
to make it a root terminal.
0) with lsblk you should see your partitions & sizes. Normally it allows
to guess which ones are the encrypted disks.
The procedure I use is (before retyping any command, read the manpage
top know / verify you do want you want to do).
1) cryptsetup luksOpen /dev/[dev-name]  ALIAS
    typically  cryptsetup luksOpen /dev/sda1  HDD  and / or cryptsetup
luksOpen /dev/sdb1  SDD
2) standard installs will use a "volume group". Before mounting you may
need to activate it:
    vgchange -a y   (a='available', y=yes=activate, n=no=deactivate)
3) mount them: mount /dev/mapper..[ qubes-volume-name ]   /somepath
4) mount your recue disc as well. You may want to encrypt your backups :
     (a) generate a huge sparse file    truncate -s 200G backup.luks
     (b) lopsetup -d   will give you a free loopback slot, like loop5
for example.
     (c) losetup  backup.luks   /dev/loop5
     (d) cryptsetup luksFormat /dev/loop5
     (e) cryptsetup luksOpen /dev/loop5  backup
     (f)  |mkfs.ext2 /dev/mapper/backup
    (g) mkdir /backup && mount /dev/mapp/er/backup  /backup
||    Now you have /backup that can be written to. Content will be
stored encrypted in your backup.luks file.
|
5) data is in  /var/lib/qubes/ 

    But (here someone may expolain it to me at the same time): the
appvms seem to be in files actually,
    with strange names, like qubes-0 qubes-1 or something of this type.
I presume they are loop-mounted
    by qubes into their respective dirs at startup. If you want to fetch
data selectively, I guess you have
    to do the same:  lopsetup -d   will give you a free loopback slot,
like loop5 for example.
    losetup file  /dev/loop5   will then generate a "device" /dev/loop5
that points to your file.
    Now mount /dev/loop5 /some-other-path allows to mount a filesystm
inside a file. Then you may go to
    /some-other-path and grab data.

when done, close your encrypted disks correctly cryptsetup luksClose
ALIAS and shutdown live-linux
samefor backup !

Good luck, Bernhard

-- 
You received this message because you are subscribed to the Google Groups 
"qubes-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/qubes-users/63332bb7-d326-a715-15e1-84bb9adcec35%40web.de.
For more options, visit https://groups.google.com/d/optout.

Reply via email to