Ubuntu – Login freeze after update to 20.04

20.04nvidianvidia-geforcevideo-driverxps

I have just upgraded from 18.04 to 20.04 on a Dell XPS 9560. The login screen was frozen and with no response on input from the mouse or keyboard.

I have booted using a recovery mode option and purged nvidia* and now I am able to log in. I can successfully login only to Ubuntu on Wayland.

If I login to regular Ubuntu, my computer freezes again immediately. On tty or Wayland, should I install nvidia drivers again (tried nvidia-440 and nvidia-435), I cannot even log in again.

I've also tried adding nouveau.nomodeset=0 to GRUB_CMDLINE_LINUX_DEFAULT, but it made no difference in my case.

I would really appreciate any advice.

Best Answer

If you choose to use proprietary binary drivers (as the nvidia-* drivers are) then you really need to approach NVIDIA to get support for them. The drivers are completely outside of the Linux kernel, and so kernel developers and Linux distributions like Ubuntu shouldn't provide end-user support for them.

That said, if you want to go down this path, you'll need to ensure the version of nvidia-* binary drivers which you install provides support for the Linux 5.4 kernel shipped in Ubuntu 20.04.


To install the latest NVIDIA proprietary drivers, you may need to disable the open source drivers first on boot:

Boot the computer and hit the Shift key to bring up the GRUB boot menu. Highlight the Ubuntu entry in the GRUB boot menu and press the E key.

Add nouveau.modeset=0 (you should use this instead of instead of nouveau.nomodeset=0) to the end of the linux line - press F10 to boot.

On the login screen press Ctrl+Alt+F1

Enter user name and password - execute:

sudo apt-get update
sudo apt-get install nvidia-driver-440
sudo reboot  

Generally it is recommended to use the NVIDIA drivers from the restricted Ubuntu repositories. This package was only updated for Ubuntu 20.04 two days ago (22 April 2020), so it's quite bleeding edge, and might be why your prior testing with a nvidia 440+ series did not work.

Alternative

As you have to find NVIDIA drivers (440.31+) which support the Linux 5.4 kernel shipped by Ubuntu, you could also install the latest official NVIDIA drivers. The xorg-edgers PPA does not provide the drivers anymore and was replaced by GPU Drivers PPA.

sudo add-apt-repository ppa:graphics-drivers/ppa
sudo apt-get update
sudo apt-get install nvidia-graphics-drivers-440
sudo reboot

After the installation adding the kernel parameter nouveau.modeset=0 is not necessary anymore.