2

I have:

~$ dpkg -l | grep -i nvidia
rc  libnvidia-compute-396:i386  396.54-0ubuntu0~gpu18.04.1  i386 NVIDIA libcompute package

When I do:

~$ sudo apt-get remove --purge libnvidia-*

this package is not removed?

Other "libnvidia" package is removed with this command, this one for example:

rc  libnvidia-compute-390:amd64   390.48-0ubuntu3      amd64  NVIDIA libcompute package

In the remove log it says:

Package 'libnvidia-compute-396' is not installed, so not removed. Did you mean 'libnvidia-compute-396:i386'?

And when I remove it with full name it gets removed.

croraf
  • 614

1 Answers1

4

Apt (or, rather dpkg) operates on the default architecture by, well, default. From the output it looks like i386 is not your default architecture, so you have to specify it. For example, see the Debian Multiarch HOWTO, which shows you have to specify the foreign architecture for both installing and removing such packages.

You could do:

sudo apt-get remove --purge 'libnvidia-.*:i386'

(Note that apt doesn't use wildcards, but regex. See apt-get remove with wildcard removed way more than expected. why?)