Score:1

Ubuntu 22.04.1 LTS upgrade : could not install nvidia-driver-470 / nvidia-driver-525

se flag

I was wondering if someone had the same problem as me when upgrading to Ubuntu 22.04.1 LTS and how to solve it.

In summary, the issue is that I am not able to install the nvidia-dkms-525 driver, which if I'm not wrong, is the correct version for the Ubuntu 22.04.1 LTS kernel.

I would much appreciate it if someone can through some lights to find a solution for this. TIA

Here you are some details about the issue:

$ sudo apt install nvidia-driver-525

Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
nvidia-driver-525 is already the newest version (525.60.11-0ubuntu0.22.04.1).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
2 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] Y
Setting up nvidia-dkms-525 (525.60.11-0ubuntu0.22.04.1) ...
update-initramfs: deferring update (trigger activated)
INFO:Enable nvidia
DEBUG:Parsing /usr/share/ubuntu-drivers-common/quirks/put_your_quirks_here
DEBUG:Parsing /usr/share/ubuntu-drivers-common/quirks/lenovo_thinkpad
DEBUG:Parsing /usr/share/ubuntu-drivers-common/quirks/dell_latitude
Removing old nvidia-525.60.11 DKMS files...
Deleting module nvidia-525.60.11 completely from the DKMS tree.
Loading new nvidia-525.60.11 DKMS files...
Building for 5.15.0-56-generic
Building for architecture x86_64
Building initial module for 5.15.0-56-generic
ERROR: Cannot create report: [Errno 17] File exists: '/var/crash/nvidia-dkms-525.0.crash'
Error! Bad return status for module build on kernel: 5.15.0-56-generic (x86_64)
Consult /var/lib/dkms/nvidia/525.60.11/build/make.log for more information.
dpkg: error processing package nvidia-dkms-525 (--configure):
 installed nvidia-dkms-525 package post-installation script subprocess returned error exit status 10
dpkg: dependency problems prevent configuration of nvidia-driver-525:
 nvidia-driver-525 depends on nvidia-dkms-525 (<= 525.60.11-1); however:
  Package nvidia-dkms-525 is not configured yet.
 nvidia-driver-525 depends on nvidia-dkms-525 (>= 525.60.11); however:
  Package nvidia-dkms-525 is not configured yet.

dpkg: error processing package nvidia-driver-525 (--configure):
 dependency problems - leaving unconfigured
No apport report written because the error message indicates its a followup error from a previous failure.
                                                                                                          Processing triggers for initramfs-tools (0.140ubuntu13.1) ...
update-initramfs: Generating /boot/initrd.img-5.15.0-56-generic
Errors were encountered while processing:
 nvidia-dkms-525
 nvidia-driver-525
E: Sub-process /usr/bin/dpkg returned an error code (1)

$ less /var/crash/nvidia-dkms-525.0.crash

ProblemType: Package
DKMSBuildLog:
 DKMS make.log for nvidia-525.60.11 for kernel 5.15.0-56-generic (x86_64)
 Mon Jan  2 06:09:44 PM CET 2023
 make[1]: Entering directory '/usr/src/linux-headers-5.15.0-56-generic'
 test -e include/generated/autoconf.h -a -e include/config/auto.conf || (               \
 echo >&2;                                                      \
 echo >&2 "  ERROR: Kernel configuration is invalid.";          \
 echo >&2 "         include/generated/autoconf.h or include/config/auto.conf are missing.";\
 echo >&2 "         Run 'make oldconfig && make prepare' on kernel src to fix it.";     \
 echo >&2 ;                                                     \
 /bin/false)
 
   ERROR: Kernel configuration is invalid.
          include/generated/autoconf.h or include/config/auto.conf are missing.
          Run 'make oldconfig && make prepare' on kernel src to fix it.
 
 make[1]: *** [Makefile:750: include/config/auto.conf] Error 1
 make[1]: Leaving directory '/usr/src/linux-headers-5.15.0-56-generic'
 make: *** [Makefile:82: modules] Error 2
DKMSKernelVersion: 5.15.0-56-generic
Date: Mon Jan  2 18:09:45 2023
Package: nvidia-dkms-525 525.60.11-0ubuntu0.22.04.1
PackageVersion: 525.60.11-0ubuntu0.22.04.1
SourcePackage: nvidia-graphics-drivers-525
Title: nvidia-dkms-525 525.60.11-0ubuntu0.22.04.1: nvidia kernel module failed to build
/var/crash/nvidia-dkms-525.0.crash (END)

$ less /var/lib/dkms/nvidia/525.60.11/build/make.log

DKMS make.log for nvidia-525.60.11 for kernel 5.15.0-56-generic (x86_64)
Mon Jan  2 07:07:48 PM CET 2023
make[1]: Entering directory '/usr/src/linux-headers-5.15.0-56-generic'
test -e include/generated/autoconf.h -a -e include/config/auto.conf || (                \
echo >&2;                                                       \
echo >&2 "  ERROR: Kernel configuration is invalid.";           \
echo >&2 "         include/generated/autoconf.h or include/config/auto.conf are missing.";\
echo >&2 "         Run 'make oldconfig && make prepare' on kernel src to fix it.";      \
echo >&2 ;                                                      \
/bin/false)

  ERROR: Kernel configuration is invalid.
         include/generated/autoconf.h or include/config/auto.conf are missing.
         Run 'make oldconfig && make prepare' on kernel src to fix it.

make[1]: *** [Makefile:750: include/config/auto.conf] Error 1
make[1]: Leaving directory '/usr/src/linux-headers-5.15.0-56-generic'
make: *** [Makefile:82: modules] Error 2
/var/lib/dkms/nvidia/525.60.11/build/make.log (END)

Here you are a pic with the error when the upgrading was in progress:

enter image description here

And Here you are a pic with the errors in the start up process (finally the OS starts, I can do login successfully, etc).

enter image description here

EDIT:

Sorry guys, I've not found a better way to attach the outputs as the Body is limited to 30000 characters and I'm trying to enter more than 40000.

enter image description here

enter image description here

enter image description here

enter image description here

enter image description here

EDIT:

It seems that all "rc" packages are already purged and in addition I have installed the nvidia-driver-525.

$ sudo apt install nvidia-driver-525

Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
nvidia-driver-525 is already the newest version (525.60.11-0ubuntu0.22.04.1).
0 upgraded, 0 newly installed, 0 to remove and 15 not upgraded.
 

$ dpkg -l | egrep '^rc'

<EMPTY>

$ apt list --installed | grep -i nvidia

WARNING: apt does not have a stable CLI interface. Use with caution in scripts.

libnvidia-cfg1-525/jammy-updates,jammy-security,now 525.60.11-0ubuntu0.22.04.1 amd64 [installed,automatic]
libnvidia-common-525/jammy-updates,jammy-updates,jammy-security,jammy-security,now 525.60.11-0ubuntu0.22.04.1 all [installed,automatic]
libnvidia-compute-525/jammy-updates,jammy-security,now 525.60.11-0ubuntu0.22.04.1 amd64 [installed,automatic]
libnvidia-compute-525/jammy-updates,jammy-security,now 525.60.11-0ubuntu0.22.04.1 i386 [installed,automatic]
libnvidia-decode-525/jammy-updates,jammy-security,now 525.60.11-0ubuntu0.22.04.1 amd64 [installed,automatic]
libnvidia-decode-525/jammy-updates,jammy-security,now 525.60.11-0ubuntu0.22.04.1 i386 [installed,automatic]
libnvidia-egl-wayland1/jammy,now 1:1.1.9-1.1 amd64 [installed,automatic]
libnvidia-encode-525/jammy-updates,jammy-security,now 525.60.11-0ubuntu0.22.04.1 amd64 [installed,automatic]
libnvidia-encode-525/jammy-updates,jammy-security,now 525.60.11-0ubuntu0.22.04.1 i386 [installed,automatic]
libnvidia-extra-525/jammy-updates,jammy-security,now 525.60.11-0ubuntu0.22.04.1 amd64 [installed,automatic]
libnvidia-fbc1-525/jammy-updates,jammy-security,now 525.60.11-0ubuntu0.22.04.1 amd64 [installed,automatic]
libnvidia-fbc1-525/jammy-updates,jammy-security,now 525.60.11-0ubuntu0.22.04.1 i386 [installed,automatic]
libnvidia-gl-525/jammy-updates,jammy-security,now 525.60.11-0ubuntu0.22.04.1 amd64 [installed,automatic]
libnvidia-gl-525/jammy-updates,jammy-security,now 525.60.11-0ubuntu0.22.04.1 i386 [installed,automatic]
linux-modules-nvidia-525-5.15.0-56-generic/jammy-updates,jammy-security,now 5.15.0-56.62+1 amd64 [installed,automatic]
linux-modules-nvidia-525-generic/jammy-updates,jammy-security,now 5.15.0-56.62+1 amd64 [installed]
linux-objects-nvidia-515-5.15.0-56-generic/jammy-updates,jammy-security,now 5.15.0-56.62+1 amd64 [installed,automatic]
linux-objects-nvidia-525-5.15.0-56-generic/jammy-updates,jammy-security,now 5.15.0-56.62+1 amd64 [installed,automatic]
linux-signatures-nvidia-5.15.0-56-generic/jammy-updates,jammy-security,now 5.15.0-56.62+1 amd64 [installed,automatic]
nvidia-compute-utils-525/jammy-updates,jammy-security,now 525.60.11-0ubuntu0.22.04.1 amd64 [installed,automatic]
nvidia-driver-525/jammy-updates,jammy-security,now 525.60.11-0ubuntu0.22.04.1 amd64 [installed]
nvidia-kernel-common-525/jammy-updates,jammy-security,now 525.60.11-0ubuntu0.22.04.1 amd64 [installed,automatic]
nvidia-kernel-source-525/jammy-updates,jammy-security,now 525.60.11-0ubuntu0.22.04.1 amd64 [installed,automatic]
nvidia-prime/jammy,jammy,now 0.8.17.1 all [installed,automatic]
nvidia-settings/jammy,jammy,now 510.47.03-0ubuntu1 amd64 [installed,automatic]
nvidia-utils-525/jammy-updates,jammy-security,now 525.60.11-0ubuntu0.22.04.1 amd64 [installed,automatic]
xserver-xorg-video-nvidia-525/jammy-updates,jammy-security,now 525.60.11-0ubuntu0.22.04.1 amd64 [installed,automatic]

enter image description here

But still I'm getting similar errors in the start up process (finally the OS starts, I can login successfully, etc).

enter image description here

Please, any idea guys ?. I'm a bit lost with this issue

nobody avatar
gh flag
Please [edit] your question and show us `dkms status` and `dpkg -l | egrep linux-'[g|i|m|k|h]|'`
cc flag
@nobody, your egrep has an extra pipe at end, messing up the search. Looks like files are missing from the headers for the 5.15.0-56 kernel, according to the error message.
nobody avatar
gh flag
Oj did not see it
cc flag
Wow, what a lot of old kernel packages. You should try sudo apt purge <pkgname> on all the kernel packages you show with lines starting with "rc". Does look like the header package is missing for the 5.15.0-56, but might have missed it. A full reinstall periodically will help avoid this sort of leftover package problem. Look into /lib/modules after the purges and see if any old dirs are left around for old kernels too, those sometimes get left.
nobody avatar
gh flag
Your DisplayLink driver block it. Please serch for evdi https://github.com/DisplayLink/evdi/issues/391
pcantoniopc avatar
se flag
Thanks guys. I have uninstalled displaylink but the issue still remains. Do you suggest then purge (apt purge <pkgname>) all packages of this search listing ? `$ dpkg -l | egrep linux-'[g|i|m|k|h]' | egrep "^rc "` Or maybe all packages of this search listing ? `$ dpkg -l | egrep "^rc "`
nobody avatar
gh flag
`dpkg -l | egrep '^rc' | awk '{print $2}' | xargs sudo dpkg -P` this removes all remaining obsolete conffiles.
nobody avatar
gh flag
I would suggest to remove any nvidia package and start fresh over Ubuntu driver gui.
pcantoniopc avatar
se flag
Ok. Thanks guys for the suggestion. I'll keep you up to date when I do it.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.