How to remove unused template countering "It is in use as: - global property default_template"

A kind of “qube in use” prevents me to uninstall fedora-43-xfce template (older template) after I tried to upgrade the template from fedora-43-xfce to fedora-44-xfce.

  • I installed fedora-44-xfce by Qubes Template Manager.
  • I shutdown qubes which I could reach from Q->Cube Symbol->Apps/Templates/Service. (Some of the did not have the option to shutdown.)
  • I switched templates from fedora-43-xfce to fedora-44-xfce by Qubes Templates Switcher.
  • I killed qubes I could reach by Q->Cube Symbol->Service (limited to those I could not shutdown).
  • I switched templates from fedora-43-xfce to fedora-44-xfce by Qubes Templates Switcher.
  • I clicked the rotating icon on the top right of the menu-bar. The notification only mentioned update of fedora-44-xfce. But, dom0, debian-13-xfce (which I installed to see what I can install by apt-command) and fedora-43-xfce were also updated.
  • I tried to uninstall fedora-43-xfce template by Qubes Template Manager. The request was refused by the message
    • VM fedora-43-xfce cannot be removed. It is in use as:
    • - global property default_template
    • qvm-template: error: Domain is in use: 'fedora-43-xfce'; see 'journalctl -u qubesd -e' in dom0 for detail
  • I restarted Qubes OS and tried uninstalling fedora-43-xfce again. The symptom did not change.

I tried the command journalctl -u qubesd -e in dom0 for detail but I do not understand its output.

  • _[0] Fedora 41 - x86_64_[?25Repositories loaded., Nothing to do., No packages downloaded.

I read through a thread I found by pretending to create at new topic.

I found the command qvm-ls is mentioned. I opened a dom0-terminal and issued the command:

  • qvm-ls | grep 43

The result was just one line.

  • fedora-43-xfce Halted TemplateVM black - -

On the other hand, the row of default-dvm on Qube Manager has fedora-44-xfce in the field of “Template”.

I read another thread, which I found in the same way as the previous one.

I checked Qube Manager->View->“Show internal qubes”. Still the string “43” is found only once. It is in the field “Name”.

I do not have the courage to use CLI to force change of default template. For example, I see differences in the strings default_template and default-mgmt-dvm template.

What is going on?

What can I do to solve the situation?

Was it a really bad idea to accept updates of templates in between upgrade to new fedora template and uninstallation of the older fedora template?

That’s fine… and did you run the next command from the linked post?
qvm-prefs default-dvm template fedora-44-xfce

Also, your error reads “* global property default_template” which you change in Qubes Global Config app, or from the dom0 command line with:
qubes-prefs default_template fedora-44-xfce
(note: this time is qubes-prefs, not qvm-prefs!)

Thank you barto,

I will try these two commands.