Using both the German versions of Winodows 10 21H1 Pro and 21H2 Pro (aka Windows 11) in VMs newly created under Qubes R4.1, I got the following results with QWT 4.1-65, using the Xen drivers version 8.2:
- After installation of QWT and reboot, qrexec works and can be used for files and clipboard copy.
- After the next reboot, both QWT services are running in Windows, but do not establish qrexec communication with Qubes, and the VM is killed after
qrexec_timeout
.
- After the next reboot, the services are working again, and so on - each second time working or not.
- The services - working or zombie - are started if they were running before the previous shutdown of Windows, irrespective of their startup mode (
Automatic
as installed, or Manual
).
- You can try to shutdown the services by using the Windows service manager, or the
net stop
command. Stopping the QrexecAgent
will crash the VM if the zombie processes are running and just stop this service if the live processes are running, Stopping the QdbDaemon
behaves a bit different: If the zombie processes are running, Windows will crash with the stop error %x0000dead
in the xenbus.sys
driver, but if the live process is running, both services will shutdown o.k., and can be restarted by using the service manager, or the net start QrexecAgent
command, which will start both, and they will establish qrexec communication.
This behaviour can be used to create, as a workaround, a working version of QWT:
- First, stop the QWT processes using the command
net stop "QdbDaemon" /yes
, which will stop both services. If the VM crashes, which will happen with a 50 % probability, just reboot and do it again.
- Then, set the startup type of both processes to
Manual
by using the Windows service manager or by executing a file Quebes_Manual.reg
, containing the following text:
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\QdbDaemon]
"Start"=dword:3
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\QrexecAgent]
"Start"=dword:3
- Shutdown and Reboot Windows. Within the
qrexec_timeout
time, execute the command net start "QrexecAgent"
. This will start a working version of QWT running both services. In order to start the services automatically, this command should be put into a file in the AutoStart
directory.
- In order to retain this working version of the QWT services, they have to be stopped before shutting down Windows again. Instead of using the normal shutdown procedure, create a file
Qubes_Shutdown.cmd
, containing the text
@echo off
net stop "QdbDaemon" /yes
choice /t 5 /d 0 /c 0 > nul
shutdown /s /t 0
- and execute this file to shutdown the VM, so next time it will start without running the QWT services. (The curious
choice
command just introduces a 5 second wait before shutdown.)
The whole procedure is not nice, but it is working. Perhaps, with the version 9.0 of the xenbus
driver in Qubes Windows Tools, it may be unnecessary, but this driver will have to be included in the QWT creation. Otherwise, it would help if QWT startup followed the startup type of the services and would start them only if this startup type was set to Automatic
.
I also tried the version 9.1 drivers, but these cannot be installed at all.