[4.1] Issue upgrading to fedora 36 in place

I’m having trouble upgrading a machine to fedora-36. I was able to do this yesterday on another machine, so am confused why it isn’t working today.

Both machines are running 4.1

Here is the error I am getting (the Dropbox error, you can ignore).

[user@fedora-36 ~]$ sudo dnf --releasever=36 distro-sync --best --allowerasing
1Password Stable Channel                        2.5 kB/s | 1.9 kB     00:00    
Dropbox Repository                               11 kB/s |  25 kB     00:02    
Errors during downloading metadata for repository 'Dropbox':
  - Status code: 404 for http://linux.dropbox.com/fedora/36/repodata/repomd.xml (IP: 127.0.0.1)
Error: Failed to download metadata for repo 'Dropbox': Cannot download repomd.xml: Cannot download repodata/repomd.xml: All mirrors were tried
Fedora 36 - x86_64                              7.6 MB/s |  81 MB     00:10    
Fedora 36 openh264 (From Cisco) - x86_64        1.3 kB/s | 2.5 kB     00:01    
Fedora Modular 36 - x86_64                      1.1 MB/s | 2.4 MB     00:02    
Fedora 36 - x86_64 - Updates                    3.5 MB/s |  20 MB     00:05    
Fedora Modular 36 - x86_64 - Updates            543 kB/s | 2.2 MB     00:04    
Qubes OS Repository for VM (updates)            411  B/s | 169  B     00:00    
Errors during downloading metadata for repository 'qubes-vm-r4.0-current':
  - Status code: 404 for https://yum.qubes-os.org/r4.0/current/vm/fc36/repodata/repomd.xml (IP: 127.0.0.1)
Error: Failed to download metadata for repo 'qubes-vm-r4.0-current': Cannot download repomd.xml: Cannot download repodata/repomd.xml: All mirrors were tried

Can anyone suggest anything? The error relating to 4.0 seems odd.

It seems you still use the 4.0 repo, fedora 36 is not available in it that’s why you’re not able to get any metadata.

Since you use 4.0, I suppose this VM is coming from a backup or an in place upgrade from 4.0.
You will need to run this script before doing anything to convert it to the 4.1 release. Then you should be able to upgrade it to Fedora 36 without issues.

I am running 4.1

I have no idea why there are calls to 4.0 resources.

You use 4.1 but the VMs can still be based on 4.0 repos. You get that now because Fedora 36 is not available in the 4.0 repo, Fedora 35 is.

Odd - how do I go about letting fedora know about 4.1?

You should download and run the script I provided, it will replace the repo and everything that need to be switched to 4.1.

wonderful - not sure how I missed your first mention of it.
ta

Don’t forget to reboot the VM after you are done with the script, then proceed with the upgrade.

will do - thanks.
And yes, I brought fedora (prob 34) with me when I did the upgrade as I really didn’t want to have to go and configure the template to make it the way it was before.

If you have some StandaloneVMs, you may have to upgrade them too, including Debian if you use it.

Hi,
I have the same issue as JustAnotherQubesUser, but errors occur during the execution of the script

Job for qubes-qrexec-agent.service failed because a timeout was exceeded.
See "systemctl status qubes-qrexec-agent.service" and "journalctl -xeu qubes-qrexec-agent.service" for details.
warning: %posttrans(qubes-core-qrexec-vm-4.1.18-1.fc35.x86_64) scriptlet failed, exit status 1

Error in POSTTRANS scriptlet in rpm package qubes-core-qrexec-vm
  Running scriptlet: qubes-core-agent-4.1.37-1.fc35.x86_64                                                                                                                                                                            253/253 
  Running scriptlet: qubes-gui-agent-4.1.26-1.fc35.x86_64                                                                                                                                                                             253/253 
  Running scriptlet: xen-runtime-4.15.3-4.fc35.x86_64                                                                                                                                                                                 253/253 
ls: cannot access '/usr/lib/xen': No such file or directory


and the VM doesn’t restart :
Fedora36

I remember having this issue with one of my StandaloneVM a long time ago, I don’t really remember how I resolved it. In case you didn’t clone the VM beforehand, you could try to revert the root volume with qvm-volume:

Hi,
Thank you for your help.
I have cloned the VM before hte upgrade, so I still have the previous version (fedora 35).
But I’ve deleted the new one and re-clone and retry to upgrade but everytime, it fails as shown in my screenshots…

What was the whole upgrade process you did? I see you went from “35” to “36” so I assume you tried to in-place upgrade the VM. Where does that template come from (installed in 4.0 or 4.1)?

When I installed Qubes at first, it came with fedora 30.
I cloned it and upgraded it to 31, and repeated these 2 actions for 32, 33, 34 and 35 (using dnf --releasever= distro-sync --best --allowerasing).
As it failed for 36, I tried your script…

I remember getting this error with that one standalone because I manually edited the repos from 4.0 to 4.1. I used the script on at least 10 StandaloneVM without getting this again so it should work for you too.

Make sure to run the script first, let it finish completely then turn off the template. Boot it up again and then do the upgrade from 35 to 36.

Is it normal to have these errors during the script execution ?

Job for qubes-qrexec-agent.service failed because a timeout was exceeded.
See “systemctl status qubes-qrexec-agent.service” and “journalctl -xeu qubes-qrexec-agent.service” for details.
warning: %posttrans(qubes-core-qrexec-vm-4.1.18-1.fc35.x86_64) scriptlet failed, exit status 1

Error in POSTTRANS scriptlet in rpm package qubes-core-qrexec-vm
Running scriptlet: qubes-core-agent-4.1.37-1.fc35.x86_64 253/253
Running scriptlet: qubes-gui-agent-4.1.26-1.fc35.x86_64 253/253
Running scriptlet: xen-runtime-4.15.3-4.fc35.x86_64 253/253
ls: cannot access ‘/usr/lib/xen’: No such file or directory

It should not fail like that. What’s your current Qubes version?

4.1 (R4.1)

xen_version            : 4.8.5-37.fc25
Linux 5.4.175-1.fc25.qubes.x86_64
  
Installed Packages:  
  
kernel-qubes-vm.x86_64                            	1000:5.4.143-1.fc25.qubes 
kernel-qubes-vm.x86_64                            	1000:5.4.156-1.fc25.qubes 
kernel-qubes-vm.x86_64                            	1000:5.4.175-1.fc25.qubes 
python2-qubesadmin.noarch                         	4.0.32-1.fc25 
python2-qubesimgconverter.x86_64                  	4.0.31-1.fc25 
python3-qubesadmin.noarch                         	4.0.33-1.fc25 
python3-qubesdb.x86_64                            	4.0.17-1.fc25 
python3-qubesimgconverter.x86_64                  	4.0.35-1.fc25 
qubes-anaconda-addon.noarch                       	4.0.11-1.fc25 
qubes-artwork.noarch                              	4.0.1-2.fc25 
qubes-core-admin-addon-whonix.noarch              	4.0.2-1.fc25 
qubes-core-admin-client.noarch                    	4.0.33-1.fc25 
qubes-core-dom0.x86_64                            	4.0.59-1.fc25 
qubes-core-dom0-linux.x86_64                      	4.0.33-1.fc25 
qubes-core-dom0-linux-kernel-install.x86_64       	 
qubes-db.x86_64                                   	4.0.17-1.fc25 
qubes-db-dom0.x86_64                              	4.0.17-1.fc25 
qubes-db-libs.x86_64                              	4.0.17-1.fc25 
qubes-desktop-linux-common.noarch                 	4.0.22-1.fc25 
qubes-desktop-linux-manager.noarch                	4.0.25-1.fc25 
qubes-dist-upgrade.noarch                         	4.0.3-1.fc25 
qubes-gpg-split-dom0.x86_64                       	2.0.55-1.fc25 
qubes-gui-dom0.x86_64                             	4.0.17-1.fc25 
qubes-img-converter-dom0.x86_64                   	1.2.11-1.fc25 
qubes-input-proxy.x86_64                          	1.0.26-1.fc25 
qubes-input-proxy-receiver.x86_64                 	1.0.26-1.fc25 
qubes-libvchan-xen.x86_64                         	4.0.9-1.fc25 
qubes-manager.noarch                              	4.0.45-1.fc25 
qubes-menus.noarch                                	4.0.22-1.fc25 
qubes-mgmt-salt.noarch                            	4.0.26-1.fc25 
qubes-mgmt-salt-admin-tools.noarch                	4.0.26-1.fc25 
qubes-mgmt-salt-base.noarch                       	4.0.4-1.fc25 
qubes-mgmt-salt-base-config.noarch                	4.0.2-1.fc25 
qubes-mgmt-salt-base-overrides.noarch             	4.0.2-1.fc25 
qubes-mgmt-salt-base-overrides-libs.noarch        	 
qubes-mgmt-salt-base-topd.noarch                  	4.0.2-1.fc25 
qubes-mgmt-salt-config.noarch                     	4.0.26-1.fc25 
qubes-mgmt-salt-dom0.noarch                       	4.0.26-1.fc25 
qubes-mgmt-salt-dom0-qvm.noarch                   	4.0.10-1.fc25 
qubes-mgmt-salt-dom0-update.noarch                	4.0.12-1.fc25 
qubes-mgmt-salt-dom0-virtual-machines.noarch      	 
qubes-pdf-converter-dom0.x86_64                   	2.1.12-1.fc25 
qubes-release.noarch                              	4.1-0.25 
qubes-release-notes.noarch                        	4.0-10 
qubes-rpm-oxide.x86_64                            	0.2.3-1.fc25 
qubes-template-debian-11.noarch                   	4.0.6-202110081812 
qubes-template-fedora-30.noarch                   	4.0.1-201912252234 
qubes-template-fedora-32.noarch                   	4.0.6-202101091318 
qubes-template-fedora-34.noarch                   	4.0.6-202110020209 
qubes-template-fedora-35.noarch                   	4.0.6-202111131804 
qubes-template-whonix-gw-15.noarch                	4.0.1-201910102356 
qubes-template-whonix-gw-16.noarch                	4.0.6-202109211111 
qubes-template-whonix-ws-15.noarch                	4.0.1-201910102356 
qubes-template-whonix-ws-16.noarch                	4.0.6-202109211111 
qubes-usb-proxy-dom0.noarch                       	1.1.1-1.fc25 
qubes-utils.x86_64                                	4.0.35-1.fc25 
qubes-utils-libs.x86_64                           	4.0.35-1.fc25 
xfce4-settings-qubes.x86_64                       	4.0.3-1.fc25 


4.1 use Xen 4.14, I see 4.8 which is used by 4.0.

In dom0, can you do this command: cat /etc/os-release
It should return “4.1”