0

I recently tried installing cuda https://developer.nvidia.com/cuda-downloads?target_os=Linux&target_arch=x86_64&target_distro=Ubuntu&target_version=1804. I opted for Linux, x86_64, Ubuntu, 18.04 (I am, in fact, running 19.10), deb (local).

Unfortunately, it didn't install correctly all the way through.

Now, I am stuck with the following series of error messages each time I use a command like sudo apt dist-upgrade or sudo apt install ... or sudo dpkg --configure -a :

Setting up nvidia-dkms-418 (418.87.01-0ubuntu1) ...
update-initramfs: deferring update (trigger activated)

A modprobe blacklist file has been created at /etc/modprobe.d to prevent Nouveau
from loading. This can be reverted by deleting the following file:
/etc/modprobe.d/nvidia-graphics-drivers.conf

A new initrd image has also been created. To revert, please regenerate your
initrd by running the following command after deleting the modprobe.d file:
`/usr/sbin/initramfs -u`

*****************************************************************************
*** Reboot your computer and verify that the NVIDIA graphics driver can   ***
*** be loaded.                                                            ***
*****************************************************************************

INFO:Enable nvidia
DEBUG:Parsing /usr/share/ubuntu-drivers-common/quirks/lenovo_thinkpad
DEBUG:Parsing /usr/share/ubuntu-drivers-common/quirks/put_your_quirks_here
DEBUG:Parsing /usr/share/ubuntu-drivers-common/quirks/dell_latitude
Removing old nvidia-418.87.01 DKMS files...

------------------------------
Deleting module version: 418.87.01
completely from the DKMS tree.
------------------------------
Done.
Loading new nvidia-418.87.01 DKMS files...
Building for 5.3.0-19-generic
Building for architecture x86_64
Building initial module for 5.3.0-19-generic
ERROR: Cannot create report: [Errno 17] File exists: '/var/crash/nvidia-dkms-418.0.crash'
Error! Bad return status for module build on kernel: 5.3.0-19-generic (x86_64)
Consult /var/lib/dkms/nvidia/418.87.01/build/make.log for more information.
dpkg: error processing package nvidia-dkms-418 (--configure):
 installed nvidia-dkms-418 package post-installation script subprocess returned error exit status 10
dpkg: dependency problems prevent configuration of nvidia-driver-418:
 nvidia-driver-418 depends on nvidia-dkms-418 (= 418.87.01-0ubuntu1); however:
  Package nvidia-dkms-418 is not configured yet.

dpkg: error processing package nvidia-driver-418 (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of cuda-drivers:
 cuda-drivers depends on nvidia-dkms-418 (>= 418.87.01); however:
  Package nvidia-dkms-418 is not configured yet.
 cuda-drivers depends on nvidia-driver-418 (>= 418.87.01); however:
  Package nvidia-driver-418 is not configured yet.

dpkg: error processing package cuda-drivers (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of cuda-runtime-10-1:
 cuda-runtime-10-1 depends on cuda-drivers (>= 418.87); however:
  Package cuda-drivers is not configured yet.

dpkg: error processing package cuda-runtime-10-1 (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of cuda-demo-suite-10-1:
 cuda-demo-suite-10-1 depends on cuda-runtime-10-1; however:
  Package cuda-runtime-10-1 is not configured yet.

dpkg: error processing package cuda-demo-suite-10-1 (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of cuda-10-1:
 cuda-10-1 depends on cuda-runtime-10-1 (>= 10.1.243); however:
  Package cuda-runtime-10-1 is not configured yet.
 cuda-10-1 depends on cuda-demo-suite-10-1 (>= 10.1.243); however:
  Package cuda-demo-suite-10-1 is not configured yet.

dpkg: error processing package cuda-10-1 (--configure):
 dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of cuda:
 cuda depends on cuda-10-1 (>= 10.1.243); however:
  Package cuda-10-1 is not configured yet.

dpkg: error processing package cuda (--configure):
 dependency problems - leaving unconfigured
Processing triggers for initramfs-tools (0.133ubuntu10) ...
update-initramfs: Generating /boot/initrd.img-5.3.0-19-generic
Errors were encountered while processing:
 nvidia-dkms-418
 nvidia-driver-418
 cuda-drivers
 cuda-runtime-10-1
 cuda-demo-suite-10-1
 cuda-10-1
 cuda

How can I help resolve this?

And if not, how can I abort this installation, so that I can normally install packages again?

1 Answer 1

2

This could be due to the fact that CUDA 10.1 is not to support Ubuntu 19.10. I was able to install and get CUDA 10.2 running on Ubuntu 19.10 (also cuDNN), but since TensorFlow works with CUDA 10.1 and not 10.2 I had to install 10.1, running to same issues. However, to abort this installation what you should do is to remove your NVIDIA driver installations:

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

and then sudo apt-get autoremove if needed. This will remove your NVIDIA drivers so apt-get will work properly again.

1
  • can't really say whether that's the solution because a new update of the NVIDIA drivers also fixed the problem :) Jan 20, 2020 at 7:06

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .