Re: NVIDIA drivers issue: Bug that keeps presenting on kernel 6.1.0-21

2024-06-20 Thread Anssi Saari
Daniel Rodriguez  writes:

> The solution of the post to this issue is to update the kernel from
> 6.1.0-13 -> 6.1.0.18; however, my kernel is a later version:
> 6.1.0-21-amd64, so I am stuck for solving this issue. Do you have any
> idea about what may be happening and/or how to solve it?

I wondered about this since I have no such issue. Then I remembered, you
need nvidia-driver from bookworm-updates.

$ uname -a
Linux rocket 6.1.0-21-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.90-1 (2024-05-03) 
x86_64 GNU/Linux
$ apt policy nvidia-driver
nvidia-driver:
  Installed: 525.147.05-7~deb12u1
  Candidate: 525.147.05-7~deb12u1
  Version table:
 *** 525.147.05-7~deb12u1 500
500 https://deb.debian.org/debian bookworm-updates/non-free amd64 
Packages
100 /var/lib/dpkg/status
 525.147.05-4~deb12u1 500
500 https://deb.debian.org/debian bookworm/non-free amd64 Packages



NVIDIA drivers issue: Bug that keeps presenting on kernel 6.1.0-21

2024-06-18 Thread Daniel Rodriguez
Hello team,

by installing NVIDIA drivers as per the guideline of Debian on Debian 12,
it shows an error as follows:

Building initial module for 6.1.0-21-amd64
> readelf: Error: Not an ELF file - it has the wrong magic bytes at the start
> readelf: Error: Not an ELF file - it has the wrong magic bytes at the start
> Error! Bad return status for module build on kernel: 6.1.0-21-amd64
> (x86_64)
> Consult /var/lib/dkms/nvidia-current/525.147.05/build/make.log for more
> information.
> dpkg: error processing package nvidia-kernel-dkms (--configure):
>  installed nvidia-kernel-dkms package post-installation script subprocess
> returned error exit status 10
> dpkg: dependency problems prevent configuration of nvidia-driver:
>  nvidia-driver depends on nvidia-kernel-dkms (= 525.147.05-7~deb12u1) |
> nvidia-kernel-525.147.05 | nvidia-open-kernel-525.147.05 |
> nvidia-open-kernel-525.147.05; however:
>   Package nvidia-kernel-dkms is not configured yet.
>   Package nvidia-kernel-525.147.05 is not installed.
>   Package nvidia-kernel-dkms which provides nvidia-kernel-525.147.05 is
> not configured yet.
>   Package nvidia-open-kernel-525.147.05 is not installed.
>   Package nvidia-open-kernel-525.147.05 is not installed.
>

I researched about it and I found this post

wherein
a person explains how to troubleshoot by enabling verbose option on dkms.
As a summary of my troubleshooting it hits the same issue. By checking out
the file /var/lib/dkms/nvidia-current/525.147.05/build/make.log as
initially the logs suggest, I found the following logs:

/bin/sh: 1: ./tools/bpf/resolve_btfids/resolve_btfids: not found
> make[3]: ***
> [/usr/src/linux-headers-6.1.0-21-common/scripts/Makefile.modfinal:63:
> /var/lib/dkms/nvidia-current/525.147.05/build/nvidia-peermem.ko] Error 127
> make[3]: *** Deleting file
> '/var/lib/dkms/nvidia-current/525.147.05/build/nvidia-peermem.ko'
>

The post

presents the bug: Debian Bug report logs - #1027306 linux-kbuild-6.0:
missing `resolve_btfids` and some scripts
, as a reason
for the log:

/bin/sh: 1: ./tools/bpf/resolve_btfids/resolve_btfids: not found


The solution of the post

to this issue is to update the kernel from 6.1.0-13 -> 6.1.0.18; however,
my kernel is a later version: 6.1.0-21-amd64, so I am stuck for solving
this issue. Do you have any idea about what may be happening and/or how to
solve it?