Following reboot of Ubuntu, nvidia drivers are no longer being used

Hi everyone, I could use some help. Graphics drivers just aren’t working suddenly after a reboot.

I’ve been happily using my graphics card for awhile. There were some issues I ran into when trying to launch Steam the other day. I wasn’t sure what was up but I knew that it’d been awhile since the Software Updater asked me to reboot. I let the updater run its thing and then rebooted.

Next thing I know, my resolution was really low. No nvidia drivers were loading. Verified through Additional Drivers that it at least believed that the drivers were installed.

Based on some searching I tried to just purge everything Nvidia-related and reinstall.

sudo apt remove --purge '^nvidia-.*'
sudo apt remove --purge '^libnvidia-.*'

After I do this and reboot I can get in and the resolution is OK but because by that point it’s seemingly using nouveau.

I then try Additional Drivers again to install the Nvidia stuff and reboot. Back to crappy resolution again.

I also tried nvidia-modprobe to maybe see if I could manually load modules that just maybe weren’t loading. I’m not sure what’s going on.

I even tried manually installing the drivers sudo apt install nvidia-driver-535 and no dice.

I’ve gone in and updated GDM to “debug=true” and run the nvidia-bug-report.sh.

Some other system details if it helps:

Ubuntu 22.04

riley@purelake:~$ uname -a 
Linux purelake 6.1.0-1015-oem #15-Ubuntu SMP PREEMPT_DYNAMIC Fri Jun 16 09:51:49 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux

riley@purelake:~$ lspci | grep -i nvidia
01:00.0 VGA compatible controller: NVIDIA Corporation GP104 [GeForce GTX 1070] (rev a1)
01:00.1 Audio device: NVIDIA Corporation GP104 High Definition Audio Controller (rev a1)
riley@purelake:~$ loginctl 
SESSION  UID USER  SEAT  TTY 
      5 1000 riley seat0 tty2

1 sessions listed.


riley@purelake:~$ loginctl show-session 5
Id=5
User=1000
Name=riley
Timestamp=Sat 2023-07-01 13:16:08 MDT
TimestampMonotonic=3437197824
VTNr=2
Seat=seat0
TTY=tty2
Remote=no
Service=gdm-password
Scope=session-5.scope
Leader=2062
Audit=5
Type=x11 <<<<<<<<<<<<< not wayland
Class=user
Active=yes
State=active
IdleHint=no
IdleSinceHint=0
IdleSinceHintMonotonic=0
LockedHint=no

nvidia-bug-report.log.gz (104.0 KB)

Figured it out. sudo apt -y install linux-headers-$(uname -r)

I’m unsure why this worked yet :D other than a loose understanding that new linux headers needed to be installed based on a new kernel that must’ve been installed recently. And in doing this, DKMS was able to rebuild nvidia stuff for the new kernel. I’m now off to the races.

If anybody is able to clarify a bit, that’d be great. Why wouldn’t new headers automagically be updated/installed when updating the kernel through software updater?

1 Like

Thank you very much!!!

I had the same problem and I solved it by installing the headers as you indicate.

There is clearly a problem with the update of the kernel to version 6.1 and the nvidia drivers, when I updated the installation entered into some kind of loop of installation and reinstallation.

uname -a
Linux orion 6.1.0-1015-oem #15-Ubuntu SMP PREEMPT_DYNAMIC Fri Jun 16 09:51:49 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux

Yes, I saw the same loop. Software updater continually asked me to approve removal of old kernel stuff. As soon as it finished, it asked again about the removal of the same. I wasn’t paying super close attention prior to noticing that, but I remember getting annoyed at how often the updater was making requests of me. Maybe it was the same kernel stuff.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.