Can a Windows StandaloneVM be made into a TemplateVM?

609 views
Skip to first unread message

Gaijin

unread,
Sep 21, 2015, 2:25:04 AM9/21/15
to qubes...@googlegroups.com
I was able to make a Windows HVM using the directions here
https://www.qubes-os.org/doc/HvmCreate/ but this created a StandaloneVM.
The VM works fine, but then I realized it's not a TemplateVM and I can't
make Windows AppVMs based on it. Rather than go through the entire
Windows install and QWT setup in another TemplateVM I wondered if it
would be possible to clone and convert the image.

I tried making a blank TemplateVM and copying the root.img over, but I
can't seem to boot into that VM in anything other than Safe Mode. It
gets to the user login, I left the default "user" account, the qrexec
timeout is set to 300, and Windows is set to log in without a username
or password. but that's as far as it gets. I get:
ERROR: Cannot start qubes-quid!

This probably isn't the right way to go about it, but I didn't see
anything related in the Docs or these forums.

I'm running Qubes 3.0-rc3
Message has been deleted
Message has been deleted

7v5w7go9ub0o

unread,
Sep 21, 2015, 8:12:06 AM9/21/15
to qubes...@googlegroups.com
Under R2, one could right click and "clone VM" the HVM using the GUI VM
manager.

Under R2, one could not convert the HVM into an AppVM; also, one could
not start up a DispVM based upon it.

If you have lots of space and are looking for a "safe" way to use a
Windows HVM in a dicey situation (which is anytime going online), I
suppose one could create a clone(s), use the clone for work, export the
data-of-interest, and simply discard the possibly-infected clone.



cprise

unread,
Sep 21, 2015, 2:41:25 PM9/21/15
to 7v5w7go9ub0o, qubes...@googlegroups.com
On 09/21/2015 07:45 AM, 7v5w7go9ub0o wrote:
>
>
> On 09/21/2015 02:24 AM, Gaijin wrote:
> Under R2, one could right click and "clone VM" the HVM using the GUI VM
> manager.
>
>

I thought R3 did not yet have Windows template support. So you are right
to mention R2. And IIRC I had successfully copied and moved Windows root
images between VMs (though I think it might have been from template to
standalone).

One thing you should try is to copy/move the private.img along with the
root. That's how I did it and should improve your chances of success.

Also remember when you create new empty HVMs, they get a measly 512MB
RAM buy default. Increase the RAM allocation for your HVM template if
you haven't already.

Jeremias E.

unread,
Sep 21, 2015, 4:27:25 PM9/21/15
to qubes-users, 7v5w7g...@gmail.com
Hello,


I thought R3 did not yet have Windows template support.

I currently use a Windows 7 template under R3.

Best regards
  J. Eppler

Gaijin

unread,
Sep 21, 2015, 10:12:13 PM9/21/15
to cprise, 7v5w7go9ub0o, qubes...@googlegroups.com
I copied
/var/lib/qubes/appvms/win7/root.img
/var/lib/qubes/appvms/win7/private.img
to
/var/lib/qubes/vm-templates/win7-x64-template/root.img
/var/lib/qubes/vm-templates/win7-x64-template/private.img

I did boost the RAM in the TemplateVM to something more reasonable.

It seems to boot now. The template is super slow compared to the
StandaloneVM. I guess I'll have to play around with it a bit. And R3
doesn't yet seem to allow creation of AppVMs based on this template,
which has been noted before. I'll probably stick to the StandaloneVM for
Windows for now.

Gaijin

unread,
Sep 21, 2015, 10:14:23 PM9/21/15
to Qubes Users
On 2015-09-21 11:41, cprise wrote:

Marek Marczykowski-Górecki

unread,
Sep 22, 2015, 7:31:35 PM9/22/15
to Gaijin, cprise, 7v5w7go9ub0o, qubes...@googlegroups.com
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

On Mon, Sep 21, 2015 at 07:12:11PM -0700, Gaijin wrote:
> I copied
> /var/lib/qubes/appvms/win7/root.img
> /var/lib/qubes/appvms/win7/private.img
> to
> /var/lib/qubes/vm-templates/win7-x64-template/root.img
> /var/lib/qubes/vm-templates/win7-x64-template/private.img
>
> I did boost the RAM in the TemplateVM to something more reasonable.
>
> It seems to boot now. The template is super slow compared to the
> StandaloneVM. I guess I'll have to play around with it a bit. And R3 doesn't
> yet seem to allow creation of AppVMs based on this template, which has been
> noted before. I'll probably stick to the StandaloneVM for Windows for now.

It should be possible to create AppVM based on HVM tempalte when you
select HVM and uncheck the "standalone" checkbox.

- --
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 v1

iQEcBAEBCAAGBQJWAeTUAAoJENuP0xzK19csor4H/RbPWvYLKqakIivwrFqOJjk8
/hC3wHWOg4mYRaYScubIaatpnZL4xGBHtzGjXvBwyxzRUL1t9Huh5pf6cR45nS3o
2OMRBSDF+Bz3zoQXCWg5rrpYeDXq5syxk6SnrOhkoCNrHBfpo7NQKTIJ4EoQDUwy
6IZeyrAIfglDuH5EpTdHloGp9zCXrufGtiHuZgutFsarySrfWfzV8ovKZmLlnGEF
doNSLD7gCppWeUJRIFCstK8mx1fBJ4LeQpEzaYWDlfzDYzeE03dYhALXjYAHDFwm
gLTP8uZE/jG/8uqrYbWnlXRTZflG4vDnh+mzIl6OtlduGlEcgJKPtegNFtgy+P4=
=SeYG
-----END PGP SIGNATURE-----

Gaijin

unread,
Sep 23, 2015, 9:46:10 PM9/23/15
to Qubes Users
> It should be possible to create AppVM based on HVM tempalte when you
> select HVM and uncheck the "standalone" checkbox.

Thanks Marek! That was the solution. I didn't realize that was an
option. My Windows templateVM then shows up as an option. The resulting
AppVM seems to run much better than the template itself.

inqubator

unread,
Mar 14, 2018, 12:56:20 PM3/14/18
to qubes-users

> I copied
> /var/lib/qubes/appvms/win7/root.img
> /var/lib/qubes/appvms/win7/private.img
> to
> /var/lib/qubes/vm-templates/win7-x64-template/root.img
> /var/lib/qubes/vm-templates/win7-x64-template/private.img
>

Hi, can I ask how you did that? When I look into the directories you mention (in R4), I don't find these files (but only "icon.png" and "firewall.xml").

Thanks

Yuraeitha

unread,
Mar 15, 2018, 7:06:46 AM3/15/18
to qubes-users

It might not be a template, but I'm not sure with RC-4, I didn't look for windows in there during RC-4. However, if it isn't acting like a template, then it might be placed elsewhere. Try go back a level, /var/lib/qubes/ and instead, look in maybe /var/lib/qubes/appvms/

Yuraeitha

unread,
Mar 15, 2018, 7:07:45 AM3/15/18
to qubes-users
On Wednesday, March 14, 2018 at 5:56:20 PM UTC+1, inqubator wrote:

If you didn't do that already of course, you might have as it's an easy suggestion.

Marek Marczykowski-Górecki

unread,
Mar 15, 2018, 3:09:51 PM3/15/18
to inqubator, qubes-users
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

In R4, use: qvm-clone --class TemplateVM

- --
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-----

iQEzBAEBCAAdFiEEhrpukzGPukRmQqkK24/THMrX1ywFAlqkTAgACgkQ24/THMrX
1ywD8wgAl413SSwuJe6GeBjh4WYUWJUoz42uGdmqA0xEGFaFRe8ZXQ41m0icKla+
nRCg+J+RAiRZPg9RE6PYsXkYTYcRHwO02NAvs5hNTfxmP4u8pzhE39FxJUGXpuyM
z4Zf1kxbGMp/gPSp/rrfU+qI9O8FYUrO1vxpwsoeahFVC/q57QveDpa9Uj6Ab0Oq
7Z4l/bxN+oa2g7aKBeq4mzNC3VHLzy9yh+K1Wf7H8mgWU7wfEM4pOmF7/+Mg7lDe
4JTqhqCAgQ0SLdq+tTF0Be4CAVw7rjNG24vHnFPZU3kP7mMtwNdVHd7AZJPaZXre
lVDeeEPuEN3zDIkMkkg76ulwT1M9oQ==
=22Ml
-----END PGP SIGNATURE-----
Reply all
Reply to author
Forward
0 new messages