How to qvm-attach VM volume to another VM?

74 views
Skip to first unread message

Chris Laprise

unread,
Nov 1, 2017, 10:40:01 PM11/1/17
to qubes-users, Marek Marczykowski-Górecki
I'm trying to repair a debian-9 root volume by first attaching it to an
appVM, but the new syntax doesn't seem to allow it. I tried the
following so far:

qvm-block attach tempvm lvm:qubes_dom0/vm-debian-9-root
qvm-block attach tempvm dom0:qubes_dom0/vm-debian-9-root
qvm-block attach tempvm dom0:/dev/mapper/qubes_dom0-vm--debian--9--root


--

Chris Laprise, tas...@posteo.net
https://github.com/tasket
https://twitter.com/ttaskett
PGP: BEE2 20C5 356E 764A 73EB 4AB3 1DC4 D106 F07F 1886

aphid...@gmail.com

unread,
Nov 2, 2017, 12:13:29 AM11/2/17
to qubes-users
On Wednesday, November 1, 2017 at 7:40:01 PM UTC-7, Chris Laprise wrote:
> I'm trying to repair a debian-9 root volume by first attaching it to an
> appVM, but the new syntax doesn't seem to allow it. I tried the
> following so far:
>
> qvm-block attach tempvm lvm:qubes_dom0/vm-debian-9-root
> qvm-block attach tempvm dom0:qubes_dom0/vm-debian-9-root
> qvm-block attach tempvm dom0:/dev/mapper/qubes_dom0-vm--debian--9--root


I'm also interested in a replacement for the old qvm-block -A functionality.

In the meantime I use losetup to get a block device for use with the new qvm-block, works for me but it's messier.

Marek Marczykowski-Górecki

unread,
Nov 2, 2017, 3:33:49 AM11/2/17
to Chris Laprise, qubes-users
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

On Wed, Nov 01, 2017 at 10:39:36PM -0400, Chris Laprise wrote:
> I'm trying to repair a debian-9 root volume by first attaching it to an
> appVM, but the new syntax doesn't seem to allow it. I tried the following so
> far:
>
> qvm-block attach tempvm lvm:qubes_dom0/vm-debian-9-root
> qvm-block attach tempvm dom0:qubes_dom0/vm-debian-9-root
> qvm-block attach tempvm dom0:/dev/mapper/qubes_dom0-vm--debian--9--root

qvm-block generally allow to attach only devices listed by it (qvm-block
ls). VM volumes are specifically excluded there.

I'd propose alternative approach for fixing debian-9: enable debug mode,
boot it, login (you'll have VGA console), then remove
xserver-xorg-legacy package. It should fix the GUI there.

- --
Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQEcBAEBCAAGBQJZ+EvfAAoJENuP0xzK19csHYQH/1lUUQley2Fxd30dgscyX21q
HfnHd6w7wfsAi1+LD1gpHN2ykHaI38c4/fxI8H7uQFH6xgFB2UmRHN1cl8CSB7YA
2yIXc3ATaG1dXSqvBC7s+ApRJHAK67DvnZtJ5PJF7QJo4yVhfbgHdRqGFMlc/Huk
yHLYoB8c4teITjtU5i2oS3pH/HfqZv5a9TMRKO+edtFZadaBJKdOLetZfUCU8V5G
zYGNGaHqRHIDE7g7qt+3bw9Nszj2tllnfY+4SkxPwobhQ1FRePCEcCBS1zxsZ8HJ
ycq0c+uCPSRQ/T8rhdf4MUNRJN6lE/b0VlM7znNCm34t+M8Ja6zVYThotyyqGB8=
=ij5H
-----END PGP SIGNATURE-----

Chris Laprise

unread,
Nov 2, 2017, 5:34:04 AM11/2/17
to Marek Marczykowski-Górecki, qubes-users
On 11/02/17 03:33, Marek Marczykowski-Górecki wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA256
>
> On Wed, Nov 01, 2017 at 10:39:36PM -0400, Chris Laprise wrote:
>> I'm trying to repair a debian-9 root volume by first attaching it to an
>> appVM, but the new syntax doesn't seem to allow it. I tried the following so
>> far:
>>
>> qvm-block attach tempvm lvm:qubes_dom0/vm-debian-9-root
>> qvm-block attach tempvm dom0:qubes_dom0/vm-debian-9-root
>> qvm-block attach tempvm dom0:/dev/mapper/qubes_dom0-vm--debian--9--root
> qvm-block generally allow to attach only devices listed by it (qvm-block
> ls). VM volumes are specifically excluded there.
>
> I'd propose alternative approach for fixing debian-9: enable debug mode,
> boot it, login (you'll have VGA console), then remove
> xserver-xorg-legacy package. It should fix the GUI there.

Already had it in debug mode; Just discovered you have to wait several
minutes for the console. But I removed xserver-xorg-legacy and its still
not right. After waiting a minute I can get xterm to run but Gnome stuff
(gnome-terminal) is broken:

> Error constructing proxy for
org.gnome.Terminal:/org/gnome/Terminal/Factory0: Failed to execute child
process "dbus-launch" (No such file or directory)

FWIW, I did an upgrade of a debian-8 template and that seems good so far.

Chris Laprise

unread,
Nov 2, 2017, 5:34:19 AM11/2/17
to aphid...@gmail.com, qubes-users, Marek Marczykowski-Górecki
That's good to know because even with private volumes you occasionally
need to attach one to an appVM for fixes/inspection without mounting it
as /home.

Marek Marczykowski-Górecki

unread,
Nov 2, 2017, 11:46:37 AM11/2/17
to Chris Laprise, qubes-users
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

On Thu, Nov 02, 2017 at 05:33:42AM -0400, Chris Laprise wrote:
> On 11/02/17 03:33, Marek Marczykowski-Górecki wrote:
> > -----BEGIN PGP SIGNED MESSAGE-----
> > Hash: SHA256
> >
> > On Wed, Nov 01, 2017 at 10:39:36PM -0400, Chris Laprise wrote:
> > > I'm trying to repair a debian-9 root volume by first attaching it to an
> > > appVM, but the new syntax doesn't seem to allow it. I tried the following so
> > > far:
> > >
> > > qvm-block attach tempvm lvm:qubes_dom0/vm-debian-9-root
> > > qvm-block attach tempvm dom0:qubes_dom0/vm-debian-9-root
> > > qvm-block attach tempvm dom0:/dev/mapper/qubes_dom0-vm--debian--9--root
> > qvm-block generally allow to attach only devices listed by it (qvm-block
> > ls). VM volumes are specifically excluded there.
> >
> > I'd propose alternative approach for fixing debian-9: enable debug mode,
> > boot it, login (you'll have VGA console), then remove
> > xserver-xorg-legacy package. It should fix the GUI there.
>
> Already had it in debug mode; Just discovered you have to wait several
> minutes for the console. But I removed xserver-xorg-legacy and its still not
> right. After waiting a minute I can get xterm to run but Gnome stuff
> (gnome-terminal) is broken:
>
> > Error constructing proxy for
> org.gnome.Terminal:/org/gnome/Terminal/Factory0: Failed to execute child
> process "dbus-launch" (No such file or directory)

Oh, indeed. You need to install dbus-x11 package for that (dbus-launch
is missing).
I hope to upload fixed template this week, if time allows...

> FWIW, I did an upgrade of a debian-8 template and that seems good so far.

- --
Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQEcBAEBCAAGBQJZ+FGRAAoJENuP0xzK19csp0YIAI9L3b82oE8IrW0S3tU8zk8x
+Ap+8praevtYNyRfjNuUO/45x6UmNz8nXH/V03V5bhvqJmpKhiGsKffFQcjVlOOS
Fz4xO9vPKEmjEu8z30tN3K1bi0sN/dYWzm2uqGMfmsj9x/K8elKUiiJ6tihppd3g
5ylA1opOGUqbxcv2hv/UOOvaJjnyYSSNr5eebjo4VI+EX+T31YmWunhrE0EdBdQs
W4IfGsUAT5PH7KLuKyAR/GVEIpxKl4mKYGVFWhpFjIauDMFI4HTFhppeZisEN+pP
DR2GxB5dx3i89PIu90cwI/Cr07qPrSyNHk+/bMXFQqgQ8BfwY396kblwRO21JaE=
=kcx4
-----END PGP SIGNATURE-----
Reply all
Reply to author
Forward
0 new messages