Can't get windows tools to install in windows VM

OK, I’m trying to follow the process to get from “no windows qube” to “windows qube” (windows 7 SP 1) as described here:

https://github.com/Qubes-Community/Contents/blob/master/docs/os/windows/windows-vm41.md/

Then here:

Then here:

Contents/windows-tools41.md at master · Qubes-Community/Contents · GitHub.

I chose to make it a template vm so I can create app qubes from it.

The first quirk I run into is on the second page where it goes into what I should do with system properties.

It says, in essence, to put all of the paging files on disk D.

There IS no disk D.

I can go into the Computer Management tool and see that there are two disks, one 2GB, one 10GB, available (in addition to the 60GB that became drive C). I can format the 10GB one, it becomes drive D…but on rebooting the template VM, it’s gone. So how am I going to set up paging files on it alone and not have the system go sideways later when there are no paging files?

OK, so if I ignore this and try to install the tools anyway, it seems to work (in this case I create the disk immediately before doing the boot with the tools installer, and I even rename it to drive Q as specified in the instructions–though since it disappears after a reboot I doubt it actually matters). I reboot once, it complains, does a self repair, then I reboot again, and lo-and-behold, there’s a second disk labeled private Qubes volume. [Edit to add: It used the 2GB disk for this, so it’s worthless for hosting swap files.]
However, my user directories are still on drive C:. (Note: Everyone used to say you could move your stuff from C: to D: but in practice I have never been able to get it to work cleanly–some cruft stays behind on C: and windows still defaults to it in some cases. Even going into the registry doesn’t help.)

The next step is to go into the registry and edit a couple of flags, but there are no branches for invisible things. So at that point I’m stuck. Windows Tools didn’t actually install, apparently.

Edit to Add: I just discovered that apparently when the system “fixes” itself after the reboot (and apparently rips out QVM tools), it re-enables all the features (i checked) and services (haven’t checked yet) I so painstakingly shut off as instructed by the second post. I do know it again requires my user name and password. So as far as I can tell, other than the presence of the small drive as drive D, all that running the install of QWT did was to revert myself to the post-Windows7 installation state.

After more time spent, I went directly from creating the vm (including making the private drive larger with qvm-volume extend $WIN_TMPL:private 12g) to installing tools–I skipped over all of the stuff about removing features, services, etc. Apparently you have to use the first of the two drives not the second, so I decided to make it bigger. I have no idea what purpose the third 10gb drive serves.

Although the Q drive goes more smoothly since I am using the first (now 12GB) drive instead of the 10 GB drive (at least the drive sticks around after I reboot), my user directory still doesn’t get moved to it even after multiple reboots and the tools don’t show any other sign of having been installed–nothing in the registry and none of the mentioned qvm-prefs are shown (other than default-user with the wrong value).

The QWT installer formats private volume and moves profile there. If there are existing partitions it doesn’t do anything with it to prevent loosing data. To get all work try to discard all changes on private volume (second one with 2g default) and reinstall QWT with move profile option

Thank you for your response!

OK, I started over (thank Bourne for scripts!). Installed windows like this ($WIN_TMPL being the name of the VM) [direct paste from my W7 create-and-install script]:

qvm-create --class TemplateVM --property virt_mode=HVM --property kernel='' --label green $WIN_TMPL

qvm-prefs $WIN_TMPL memory 4096
qvm-prefs $WIN_TMPL maxmem 4096
qvm-volume extend $WIN_TMPL:root 60g
qvm-volume extend $WIN_TMPL:private 5g
qvm-prefs $WIN_TMPL qrexec_timeout 7200

Then
qvm-start --cdroom=<iso file path and name> $WIN_TMPL

So that installed windows 7 sp 1.

Once installed I did “bcdedit /set testsigning on” and also used netplwiz to disable having to enter passwords.

Nothing else.

I then shut down, and restarted with

qvm-start w7sp1-tmpl --install-windows-tools

I enabled everything.

New disk was D: (not Q: as the instructions indicate it ought to be, which is why I was trying to format the thing in the first place)

I rebooted multiple times more than needed (because I read something that said it had to reboot to copy the files) and my user area never got moved. Also qvm-prefs does not show the three values the instructions indicate would be there. And, the keys that are supposed to be in the registry aren’t there either.

In other words, not formatting the disk beforehand had no effect except to change the resulting drive letter from Q to D.

It still isn’t installing or doing anything else other than formatting the private disk.

Update: I’ve tried removing features in the install wizard, thinking one of them might be causing a problem.

Removing the one xen driver that is enabled by default results in a system that hangs halfway through the boot (though it doesn’t go trying to repair itrself).

Installing ONLY that xen driver, plus the common components, and nothing else, gives the same result. (Just as well, because it would be useless in this configuration.)

Again, the three prefs that are supposed to be added, aren’t, and the invisible software company does not show in the registry. No indication whatsoever it got installed.

What QWT version do you try to install?

I issued this command:

sudo qubes-dom0-update --enablerepo=quebes-dom0-current-testing qubes-windows-tools

a couple of days ago, so presumably the most recent one. Judging from the still-mounted copies of it in dom0, it was 4.1.68.1.

I suppose Windows 7 SP1 requires some updates after installation, that might be the reason or you could try to get iso from qvm-create-windows-qube script…

I suppose I could try a different windows 7 SP 1 iso. Do you know of one that has worked for other people?

My dom0 doesn’t know about that script (command not found).

In the meantime, W7SP1 appears functional as a VM…but I haven’t figured out how to get files into it from other qubes (without QWT installed that is). Even USB thumbdrives seem to be totally invisible to it (even after being assigned to it by dom0). (I also couldn’t get it to see a dvd rom player.) [This is true even if I fire up computer management’s storage tab, which usually can do almost anything with drives, either external or USB.]

Can you point me to some ideas there, so that I can be productive with it in the meantime?

Well, if your keyboard/mouse aren’t connected to the only USB controller on the device, you could try assigning a usb pci controller to the windows hvm, starting it and connecting a device to a USB port that is part of the usb controller.

B

Unfortunately, although my system CLAIMS to have four USB controllers, apparently all of the actual physical plugs (including the keyboard and mouse) go to USB1.

[at some point in the future I’m going to tackle a USB qube but that’s going to be a scary process because it’s apparently all too easy to brick your system with it under my circumstances.]

Thanks, I’ll try that tonight–assuming I can get a decent connection for downloading a multi-gigabyte file.

One possible difficulty is that my license is for Pro, not ultimate. However, I might (given that URL) be able to find a Pro ISO “nearby” on their site. (I wish I could remember where I got my current ISO. I just know its name is Win7_Pro_SP1_English_x64.iso)

UPDATE:

I’m getting good download speed, miracle of miracles.

I found a utility here: winisoutils - Windows ISO Disc Image Utilities (linked from a Micro$haft page) that removes a file from the iso; that file determines which version of W7SP1 is installed. Without that file in the ISO, you get to pick the one that matches your license during install. So I should be able to use the recommended ISO to install pro.

I found a way to move files, but it’s a bit cumbersome. On my NAS I created a dropbox folder. I was able to get the Windows VM to connect to the NAS with a share. I have other (Linux) VMs that talk to it as well, so to send a file TO the windows VM, I first send it to one of these qubes, which can move the file into the dropbox. It’s a bit of a circus having an intermediate qube involved, but I can move files now. (I created a standalone VM from the template VM for this so I don’t have to redo everyting over and over again.)

Yet another update:

The iso installed ultimate, even though I supposedly removed that one file on it with the utility. (I will try to find a way to manually do it.)

The bigger problem is that “seamless mode” seems to be hopelessly broken on a two monitor system. Starting it up covers one monitor, but the password prompt is centered as if it were covering both monitors. I get that obnoxious “a virtual machine tried to open a very large window” balloon (that you can’t read the critical parts of (like what to click on) because the text is truncated).

Upon entering the password (which I thought I had disabled), the window simply crashed. (The machine is shown as still running. But nothing will actually start on it.)

[Edit: Either disabling the password (for real) or something else I did made it work. Now I don’t get a desktop, but I CAN start apps, much like other things. I can also move files (most important!), because I remembered to qvm-prefs the default user.

Now if only I had a license for ultimate…

I’m going to call this solved.

TL;DR is that my Win 7 pro ISO was a piece of junk; I had to go get another. (Thanks jevank for triggering that thought process.)

However you might find the following observations useful:

Mostly, jevank got me to look at other ISOs, so he gets a good bit of credit for this. The ISO I started with was bad, apparently. I found another windows 7 pro ISO but the source might be kind of dodgy (fortunately my windows AppVM qube won’t communicate with anything). The name was of the same format as the Ultimate ISO he pointed me to, and of almost if not exactly the same size (my original one was much smaller).

A couple of observations:

  1. supposedly windows 7 ISOs come with a file (sources/ei.cfg) that if absent, will cause the installer to prompt you to select which one (pro, home, ultimate, whatever) it will install. (Note that you what you install has to match your license key, though!) The recommended Ultimate ISO doesn’t have this file but even so, won’t give you the choice. I tried to grab the ei.cfg file from my (defective) windows pro ISO, to sort of force the ultimate ISO to install Pro anyway, but I couldn’t for the life of me make even a thumbdrive made from the ultimate ISO not read only (and yes I tried hdparms). I have no idea if this idea would have worked or not.

1a) The pro ISO really didn’t like one or the other of the two optional xen drivers. I don’t recall if I tried using all three with the Ultimate ISO pointed to by jevank above.

1b) one of the peculiarities of the bad ISO I had was that the confirmation dialogs that come up during QWT installation don’t look like the ones in the documentation. I originally ascribed this to differences between pro and ultimate; but no it is the difference between an ISO that will work here, and one that won’t.

1c) [edit to add] I just realized I should go back to the site where I found the pro ISO and download their ultimate ISO…and compare it with the one from the microsoft site. If they are identical, then they probably didn’t monkey with the pro ISO. If they aren’t, they probably did.

  1. After install of QWT, but even before I enabled seamless mode in the registry, it was acting very wonky, with the qube apparently running but nothing opening. This appears to be at least in part due to the windows user ID (my initials) not matching the one on qubes (user). This is fixable (and documented as such) with qw-prefs, changing the default user to what it actually is…but probably ought to be emphasized…this MUST be done before you install QWT. (Better yet would be for the QWT installer to somehow take care of that…if that’s even possible, which it probably isn’t. However, since you have to fire the whole process up from dom0 perhaps it could be done automagically there?)

  2. Some of the apps I have installed on Windows (Micro$haft Office, Libre Office [and yes I do need both]) initially open full screen. If you are in seamless mode when you start the app for the first time, this causes really wonky behavior: You end up trying to resize a gargantuan window and the app likes to scroll your document page off the screen as you try to shrink the window. This is easily fixed by shifting out of seamless mode, un-fullscreening the app, perhaps manually shrinking the window a bit, then going back to seamless. [Note: For all I know this is only an issue for dual-monitor setups.]

  3. It’s really strange using windows without a start menu! (Of course switching away from seamless gives it back to you.) When you start the qube for the first time, it seems like all of the apps included with windows show up in the flyout from the Q menu (upper left menu) [and probably also from the right mouse button menu from the desktop]. Going into qubes settings shows all the apps on the left side (meaning they shouldn’t be displayed). To clear this up, move them all to the right, apply, then move them back to the left and hit apply. Then construct the list how you like (I ended up with windows explorer [the file manager] and command.com [the terminal] and a couple of apps over on the right hand side; more apps after I installed them). This same process repeats after you make an AppVM from the template VM [if that’s what you did, rather than just a standalone], only this time in order to clear it up you have to refresh the list of apps, which takes five to ten minutes because it will fire up the templateVM as well as the App VM; and then do the two-step I just described.

  4. Probably the only genuine bug, and it’s really a user interface complaint: On the settings window, the two buttons that enable and disable seamless mode…one of them should always be desensitized [the one that puts you in the mode you’re already in]. Better yet, it should be a checkbox that reads “Seamless mode” or “Enable seamless mode” and always sensitized when there is such a thing for that vm as “seamless mode.”

You can get the Windows menu by starting some program (like Windows Explorer), positioning the cursor into this program’s window, and then hitting the Windows key on your keyboard. For this reason, I nearly all of the time I have Windows Explorer running.

Depending on your graphic controller, the Windows menu may open quite slowly - at least on one of my machines having an Nvidia card, it does so.

1 Like

Same here…explorer running. I can get to most things there even without the trick you just told me. (I’ve even added it as a favorite to the “new” menu.)

The start menu apparently pops up in the lower left of my left hand monitor (not necessarily anywhere near my actual explorer window).

I’m noticing my template keeps popping up a network settings window when I start it. Since it’s connecting to a “no actual network” firewall controller (in case I need the network for inter-qube things–I don’t know one way or the other. Wait, is that how the time is distributed?), I may just disconnect that.

Also:

This site:

Appears to have links to Microsoft’s ISOs for ALL levels of Windows 7 (pro, home. ultimate, etc.)

The ISO I used matches the one on this site even though it came from somewhere else.