Failed to log in graphical session after upgrade #f37 —> #f39

,

Hi :wave:
I tried to upgrade f37f39 using this manual
and eventually I got:

“Oh no, something has gone wrong. A problem has occurred and the system can’t recover. Please contact a system administrator.”

  • I have enough disk space
  • I can login via tty

cat /etc/fedora-release
Fedora release 39 (Thirty Nine)

ls -l /usr/bin/dnf
lrwxrwxrwx. 1 root root 5 Oct 19 16:04 /usr/bin/dnf -> dnf-3*

journalctl errors and failures

Can anybody help me to fix it?

Hello @chakka ,
Did you first make sure your F37 was fully up to date? You can do this with sudo dnf distro-sync. After it completes you should be able to do the upgrade.

I was following this Upgrading Fedora Using DNF System Plugin :: Fedora Docs

and achieved the last command

sudo dnf system-upgrade reboot

which rebooted and started upgrade.
upgrade finished successfully, I got problem after reboot

So the upgrade completed and you can log into the tty but not the gui is that the problem?

yes. in normal reboot I’m getting in that famous “oh no…” error screen

So I’ll ask again, can you log into the terminal after upgrade?

yes, I can get to tty and login there.

Do you have nvidia graphics?
[Edit] If so please read this post Third-party modules (e.g. Nvidia) are not rebuilt during system upgrade

no, I don’t have nvidia. I have Thinkpad t480 with intel UHD 620

I have a ThinkPad E530 Edge that I had an issue upgrading some time back. What was happening there was the whole upgrade would finish then fail to actually write the EFI entry due to the flash area being full. I had to delete files in my efivars that had $DUMP in their filename to free up space in my BIOS flash area. I assumed they were related to Lenovo diagnostics and of no consequence. Anyway after doing that and repeating the upgrade process I was able to boot into an upgraded system. I am not saying you’re facing the same issue but it may be worth checking your efivars to see. You can find out by using ls ls /sys/firmware/efi/efivars/.
[Edit] I took a number of days searching both in Fedora community and elsewhere, and I found the answer on stack exchange and it was specifically for Unbuntu, but using a Lenovo ThinkPad.

Hello @chakka ,
If you don’t mind, could you post the terminal text itself between with the “</>” button? It makes it very much easier to read.
[Edit] Also, can you let me know how comfortable you are with doing command line activities with your PC? And please understand that I am not recommending you have the same issue I had, but this is an avenue of investigation you can pursue. I had to find out about how Lenovo handled my laptops flash (it’s over two chips in my case), and I had to first verify that my flash area was running out of space. Perhaps @mpearson has some thoughts.

yeah, I also prefer formatted text, but I still can’t send all this output to my mobile :grin:

Also, can you let me know how comfortable you are with doing command line activities with your PC?

I’m super-comfortable with CLI usually

thank you so much for your help :pray:

added some new journalctl error and failures logs to first message

I also found out that dnf is not working:

$ dnf
Traceback (most recent call last):
  File “/usr/bin/dnf”, line 61, in <module>
    from dnf.cli import main
ModuleNotFoundError: No module named ‘dnf’

Fedora 39 updates to python 3.12. dnf is written in python, and that error shows that the python on your path is not the python that dnf needs. Check that you don’t have an old python on your path and that you don’t have any active python virtual environments. Also, it might help to run dnf as root. On my Fedora 39 laptop, rpm -q shows that I have python3-3.12.1-2.fc39.x86_64 and dnf-4.18.2-1.fc39.noarch . If you still have the fc37 versions of either one, something might have gone wrong when you did the update. I did the same update as you from 37 to 39 (skipping 38) without any problems.

sudo dnf

gives me absolutely the same error

$ rpm -q python3
python3-3.12.1-2.fc39.x86_64
$ which python
/home/xuser/.pyenv/shims/python
$ python —version
Python 3.12.1

@william8000 by the link which you provided were suggested many ways to solve the problem. which one should I prefer?

If you have critical F37 packages they certainly may interfere with functionality.

Please try sudo dnf distro-sync --refresh and see if it does anything about bringing the appropriate packages up to date with the current fedora release.

I have a system that has been repeatedly upgraded from about F32 and this is the total list of packages that are not at the fc39 versions.

$ dnf list installed | grep -E 'fc32|fc33|fc34|fc35|fc36|fc37|fc38'
NetworkManager-ssh.x86_64                            1.2.12-5.fc38                          @fedora                         
NetworkManager-ssh-gnome.x86_64                      1.2.12-5.fc38                          @fedora                         
b43-openfwwf.noarch                                  5.2-30.fc38                            @fedora                         
bitstream-vera-sans-fonts.noarch                     1.10-48.fc38                           @fedora                         
fwupd-efi.x86_64                                     1.4-1.fc38                             @fedora                         
gfbgraph.x86_64                                      0.2.5-3.fc38                           @fedora                         
iscan-firmware.noarch                                20190508-9.fc38                        @fedora                         
libgpuarray.x86_64                                   0.7.6-19.fc38                          @fedora                         
netcdf.x86_64                                        4.9.0-5.fc38                           @fedora                         
nim-srpm-macros.noarch                               3-8.fc38                               @fedora                         

dnf is broken :slightly_smiling_face:
I’m trying to fix it via reinstall python with rpm, but there are also problems there…

Sorry, I missed that.
It is possible to fix by downloading the appropriate rpms but I do not know the details. Someone may be able to guide you as to which packages to reinstall.