Using "Software and Updates -> Additional Drivers" to Switch Fails

Bug #1753333 reported by Chris McDonough on 2018-03-04
28
This bug affects 5 people
Affects Status Importance Assigned to Milestone
software-properties (Ubuntu)
High
Alberto Milone
Bionic
Undecided
Unassigned

Bug Description

SRU Request:

[Impact]
Currently, the Additional Drivers tool uninstalls only the driver package that ships the modaliases. When it comes to the NVIDIA drivers (>=390), that package is only a meta-package. Removing the meta-package will not uninstall the driver.

We should make sure to uninstall all its nvidia related dependencies, not only the meta-package.

[Test Case]
1) Open the "Software & Updates" app, and select the "Additional Drivers" tab

2) Uninstall the NVIDIA 390 driver

3) Check that, for example, the nvidia-dkms-390 package was uninstalled:

apt-cache policy nvidia-dkms-390

The package will be reported as installed, because the current code didn't remove it.

[Regression Potential]
Relatively low, as the change in behaviour only affects the nvidia driver, and it only causes the Additional Drivers tool to remove dependencies of the meta-package that have the "nvidia" string in their name.

__________________
When you are in the initial install state, you can easily switch from the Nouvea drivers to the Nvidia drivers by choosing the option in "Software and Updates -> Additional Drivers". However, when you attempt to switch back (by selecting the nouveau option and clicking Apply), and subsequently reboot, your system will still come up using the Nvidia drivers, and you will WTF.

And then, if you visit Additional Drivers, you will be presented with grayed out options for both nvidia and nouvea, and the only selectable option will be "continue using manually installed driver".

The reason for this is that the tool, when reselecting nvidia in the GUI, uninstalls the nvidia-drivers-390 package, but because it's a metapackage (or at least I presume this is the reason), it doesn't uninstall its dependencies, which causes the Additional Drivers tool to believe it's in a non-automanaged state, and the nvidia drivers never actually get uninstalled.

You can fix it by doing an apt autoremove and rerunning the Additional Drivers tool. But obviously there is no real way for inexperienced users to know this.

Related branches

Chris McDonough (chrism-plope) wrote :

The rationale about why this is a probably an important bug to fix:

https://bugs.launchpad.net/ubuntu/+source/nvidia-graphics-drivers-390/+bug/1752739/comments/5

Doug McMahon (mc3man) wrote :

Correct, removing the nvidia-drivers-390 package does nothing.
Using sudo apt purge nvidia* is somewhat effective but to really remove nvidia that has to be followed by sudo apt purge *nvidia
The current state disenfranchises optimus owners who now can't easily switch & get a crappy tear ridden experience on nvidia..

Changed in nvidia-graphics-drivers-390 (Ubuntu):
status: New → Confirmed
Changed in nvidia-graphics-drivers-390 (Ubuntu):
assignee: nobody → Alberto Milone (albertomilone)
importance: Undecided → High
status: Confirmed → Triaged
Changed in software-properties (Ubuntu):
status: New → Triaged
assignee: nobody → Alberto Milone (albertomilone)
importance: Undecided → High
Changed in software-properties (Ubuntu):
status: Triaged → In Progress
no longer affects: nvidia-graphics-drivers-390 (Ubuntu)
Alberto Milone (albertomilone) wrote :

The fix for this bug is in the bazaar branch listed above.

Alberto Milone (albertomilone) wrote :

The code in my MP was approved. Please merge it, and let's proceed with the SRU.

description: updated

Hello Chris, or anyone else affected,

Accepted software-properties into bionic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/software-properties/0.96.24.32.2 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed.Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-bionic to verification-done-bionic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-bionic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

Changed in software-properties (Ubuntu Bionic):
status: New → Fix Committed
tags: added: verification-needed verification-needed-bionic
Kev Bowring (flocculant) wrote :

@albertomilone - could we have a fix for bug 1761593 ? I did try on the off-chance using the updated software-properties from proposed - but I was left having to rm /etc/modprobe.d/nvidia-340.conf

Launchpad Janitor (janitor) wrote :

This bug was fixed in the package software-properties - 0.96.24.33

---------------
software-properties (0.96.24.33) cosmic; urgency=medium

  * cloudarchive: Enable support for the Rocky Ubuntu Cloud Archive on
    18.04 (LP: #1769920).

 -- Corey Bryant <email address hidden> Tue, 08 May 2018 10:58:48 -0400

Changed in software-properties (Ubuntu):
status: In Progress → Fix Released
Bump (bump55) wrote :

Running bionic-proposed here and still can't see software-properties (0.96.24.33):

root@ubuntu:~# dpkg -l | grep software-properties
ii python3-software-properties 0.96.24.32.2 all manage the repositories that you install software from
ii software-properties-common 0.96.24.32.2 all manage the repositories that you install software from (common)
ii software-properties-gtk 0.96.24.32.2 all manage the repositories that you install software from (gtk)
ii software-properties-kde 0.96.24.32.2 all manage the repositories that you install software from (qt)

Brian Murray (brian-murray) wrote :

The version for bionic is 0.96.24.32.2. The other version is for cosmic, the new development release of Ubuntu.

Brian Murray (brian-murray) wrote :

I went ahead and verified this on bionic.

Start-Date: 2018-05-17 11:32:08
Commandline: apt-get install software-properties-gtk
Requested-By: bdmurray (1000)
Upgrade: python3-software-properties:amd64 (0.96.24.32.1, 0.96.24.32.2), software-properties-gtk:amd64 (0.96.24.32.1, 0.96.24.32.2), software-properties-common:amd64 (0.96.24.32.1, 0.96.24.32.2)
End-Date: 2018-05-17 11:32:13

Start-Date: 2018-05-17 11:34:44
Commandline: aptdaemon role='role-commit-packages' sender=':1.123'
Remove: libnvidia-compute-390:amd64 (390.48-0ubuntu3), libnvidia-encode-390:amd64 (390.48-0ubuntu3), xserver-xorg-video-nvidia-390:amd64 (390.48-0ubuntu3), libnvidia-gl-390:amd64 (390.48-0ubuntu3), libnvidia-fbc1-390:amd64 (390.48-0ubuntu3), libnvidia-decode-390:amd64 (390.48-0ubuntu3), libnvidia-cfg1-390:amd64 (390.48-0ubuntu3), nvidia-utils-390:amd64 (390.48-0ubuntu3), nvidia-dkms-390:amd64 (390.48-0ubuntu3), nvidia-compute-utils-390:amd64 (390.48-0ubuntu3), libnvidia-ifr1-390:amd64 (390.48-0ubuntu3), nvidia-driver-390:amd64 (390.48-0ubuntu3), nvidia-kernel-source-390:amd64 (390.48-0ubuntu3)
End-Date: 2018-05-17 11:35:01

tags: added: verification-done-bionic
removed: verification-needed-bionic
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package software-properties - 0.96.24.32.2

---------------
software-properties (0.96.24.32.2) bionic; urgency=medium

  * SoftwarePropertiesGtk.py: uninstall the actual nvidia packages,
    not only the meta-package (LP: #1753333).

 -- Alberto Milone <email address hidden> Wed, 02 May 2018 15:58:01 +0200

Changed in software-properties (Ubuntu Bionic):
status: Fix Committed → Fix Released

The verification of the Stable Release Update for software-properties has completed successfully and the package has now been released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers