Instance for NVIDIA drivers in Dell G15 5511, Debian 11 "Bullseye"

Hello, would you please help me?

Issue:
Drivers troubleshooting. Black screen at the beginning of booting. Need to enter ‘nomodeset’ parameter to boot.
For the installation, followed the procedure of Debian’s main page: NvidiaGraphicsDrivers - Debian Wiki. I installed version 470.103.01.
Read all the forum’s threads similar to mine.

Generated nvidia-bug-report log file, please find it attached.

DETAILS

Laptop: Dell G15 5511

Card (Optimus)

lspci -nn | egrep -i “3d|display|vga”

00:02.0 VGA compatible controller [0300]: Intel Corporation Device [8086:9a68] (rev 01)
00:17.0 SATA controller [0106]: Intel Corporation Device [8086:43d3] (rev 11)
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GA107 [10de:25a2] (rev a1)

OS: Debian “Bullseye” 11.3

Kernel: 5.10.0-13-amd64

Kernel headers installed:

ls -l

total 20
drwxr-xr-x 4 root root 4096 Apr 6 22:14 linux-headers-5.10.0-13-amd64
drwxr-xr-x 4 root root 4096 Apr 6 22:14 linux-headers-5.10.0-13-common
drwxr-xr-x 4 root root 4096 Apr 6 19:14 linux-headers-5.16.0-0.bpo.4-amd64
drwxr-xr-x 4 root root 4096 Apr 6 19:14 linux-headers-5.16.0-0.bpo.4-common
lrwxrwxrwx 1 root root 24 Mar 17 15:40 linux-kbuild-5.10 -> ../lib/linux-kbuild-5.10
lrwxrwxrwx 1 root root 24 Mar 8 19:36 linux-kbuild-5.16 -> ../lib/linux-kbuild-5.16
drwxr-xr-x 9 root root 4096 Apr 6 22:17 nvidia-current-470.103.01

gcc --version

gcc (Debian 10.2.1-6) 10.2.1 20210110

I also installed CUDA:

nvcc --version

Cuda compilation tools, release 11.2, V11.2.152
Build cuda_11.2.r11.2/compiler.29618528_0

Syslog:

less /var/log/syslog | grep -i NVIDIA

Apr 7 10:55:41 Bit-Force systemd-modules-load[329]: modprobe: ERROR: could not insert 'nvidia_current': Operation not permitted
Apr 7 10:55:41 Bit-Force systemd-modules-load[327]: modprobe: ERROR: ../libkmod/libkmod-module.c:990 command_do() Error running install command 'modprobe -i nvidia-current ' for module nvidia: retcode 1
Apr 7 10:55:41 Bit-Force systemd-modules-load[327]: modprobe: ERROR: could not insert 'nvidia': Invalid argument
Apr 7 10:55:41 Bit-Force systemd-modules-load[336]: modprobe: ERROR: could not insert 'nvidia_current_modeset': Operation not permitted
Apr 7 10:55:41 Bit-Force systemd-modules-load[325]: modprobe: ERROR: ../libkmod/libkmod-module.c:990 command_do() Error running install command 'modprobe nvidia ; modprobe -i nvidia-current-modeset ' for module nvidia_modeset: retcode 1
Apr 7 10:55:41 Bit-Force systemd-modules-load[325]: modprobe: ERROR: could not insert 'nvidia_modeset': Invalid argument
Apr 7 10:55:41 Bit-Force systemd-modules-load[370]: modprobe: ERROR: could not insert 'nvidia_current_drm': Operation not permitted
Apr 7 10:55:41 Bit-Force systemd-modules-load[305]: Error running install command 'modprobe nvidia-modeset ; modprobe -i nvidia-current-drm ' for module nvidia_drm: retcode 1
Apr 7 10:55:41 Bit-Force systemd-modules-load[305]: Failed to insert module 'nvidia_drm': Invalid argument
Apr 7 10:55:41 Bit-Force systemd-udevd[389]: modprobe: ERROR: could not insert 'nvidia_current': Operation not permitted
Apr 7 10:55:41 Bit-Force systemd-udevd[365]: Error running install command 'modprobe -i nvidia-current ' for module nvidia: retcode 1
Apr 7 10:55:41 Bit-Force systemd[1]: Starting NVIDIA Persistence Daemon...
Apr 7 10:55:41 Bit-Force nvidia-persistenced: Started (504)
Apr 7 10:55:41 Bit-Force kernel: [ 2.074101] input: HDA NVidia HDMI/DP,pcm=3 as /devices/pci0000:00/0000:00:01.0/0000:01:00.1/sound/card0/input17
Apr 7 10:55:41 Bit-Force kernel: [ 2.148363] input: HDA NVidia HDMI/DP,pcm=7 as /devices/pci0000:00/0000:00:01.0/0000:01:00.1/sound/card0/input18
Apr 7 10:55:41 Bit-Force kernel: [ 2.148436] input: HDA NVidia HDMI/DP,pcm=8 as /devices/pci0000:00/0000:00:01.0/0000:01:00.1/sound/card0/input19
Apr 7 10:55:41 Bit-Force kernel: [ 2.148485] input: HDA NVidia HDMI/DP,pcm=9 as /devices/pci0000:00/0000:00:01.0/0000:01:00.1/sound/card0/input20
Apr 7 10:55:41 Bit-Force nvidia-persistenced: Failed to query NVIDIA devices. Please ensure that the NVIDIA device files (/dev/nvidia*) exist, and that user 116 has read and write permissions for those files.
Apr 7 10:55:41 Bit-Force nvidia-persistenced: Shutdown (504)
Apr 7 10:55:41 Bit-Force nvidia-persistenced[493]: nvidia-persistenced failed to initialize. Check syslog for more details.
Apr 7 10:55:41 Bit-Force systemd[1]: nvidia-persistenced.service: Control process exited, code=exited, status=1/FAILURE
Apr 7 10:55:41 Bit-Force nvidia-persistenced: Failed to unlock PID file: Bad file descriptor
Apr 7 10:55:41 Bit-Force nvidia-persistenced: Failed to unlink PID file: No such file or directory
Apr 7 10:55:41 Bit-Force nvidia-persistenced: Shutdown (504)
Apr 7 10:55:41 Bit-Force systemd[1]: nvidia-persistenced.service: Failed with result 'exit-code'.
Apr 7 10:55:41 Bit-Force systemd[1]: Failed to start NVIDIA Persistence Daemon.
Apr 7 11:10:14 Bit-Force kernel: [ 874.114902] process 'lib/nvidia-cuda-toolkit/bin/nvcc' started with executable stack
Apr 7 11:11:29 Bit-Force nvidia-persistenced: Failed to create directory /var/run/nvidia-persistenced: Permission denied
Apr 7 11:11:29 Bit-Force nvidia-persistenced: Unable to access /var/run/nvidia-persistenced: No such file or directory
Apr 7 11:11:29 Bit-Force nvidia-persistenced: Shutdown (15940)
Apr 7 11:12:16 Bit-Force nvidia-persistenced: Started (15974)
Apr 7 11:12:16 Bit-Force nvidia-persistenced: Failed to query NVIDIA devices. Please ensure that the NVIDIA device files (/dev/nvidia*) exist, and that user 0 has read and write permissions for those files.
Apr 7 11:12:16 Bit-Force nvidia-persistenced: Shutdown (15974)
Apr 7 11:12:43 Bit-Force nvidia-persistenced: Started (16004)
Apr 7 11:12:43 Bit-Force nvidia-persistenced: Failed to query NVIDIA devices. Please ensure that the NVIDIA device files (/dev/nvidia*) exist, and that user 0 has read and write permissions for those files.
Apr 7 11:12:43 Bit-Force nvidia-persistenced: Shutdown (16004)

Boot.log:

less /var/log/boot.log | grep -i NVIDIA

Starting NVIDIA Persistence Daemon...
Starting NVIDIA Persistence Daemon...
Starting NVIDIA Persistence Daemon...
[FAILED] Failed to start NVIDIA Persistence Daemon.
See 'systemctl status nvidia-persistenced.service' for details.
Starting NVIDIA Persistence Daemon...
[FAILED] Failed to start NVIDIA Persistence Daemon.
See 'systemctl status nvidia-persistenced.service' for details.
Starting NVIDIA Persistence Daemon...
Starting NVIDIA Persistence Daemon...
Starting NVIDIA Persistence Daemon...
Starting NVIDIA Persistence Daemon...

Looking forward to hearing from you.
Best,

Ernest
nvidia-bug-report.log.gz (67.1 KB)

Please run nvidia-bug-report.sh as root and attach the resulting nvidia-bug-report.log.gz file to your post.

Hello, thanks for replying.

I attached it when I edited the thread the first time, but perhaps something went wrong.
I reattached it, please find it.

Ernest

Please disable secure boot.

Hello.

Done. Unfortunately, the consequences were apparently bad.
The loading got blocked in the CUPS service or CUPS scheduler service.

But I had the possibility to save the logs file and to make another nvidia bug log file. Please, find them attached here.
boot.log (31.6 KB)
nvidia-bug-report.log.gz (236.2 KB)
syslog (2.9 MB)

Please remove ‘nomodeset’ kernel parameter.

Hello,

If I remove ‘nomodeset’ Linux can’t boot. The crash occurs immediately after the GRUB menu. The only way I have to load Linux and enter commands is through ‘nomodeset’.

Your system is a hybrid graphics system which won’t ever work with the nomodeset parameter. Please create a log without it.

I can’t create a log as the system crashes before Linux is loaded.
Please watch the video attached.

The only way to load Linux is through ‘nomodeset’. I understand that it’s a loop, but I need please you to help me to find a solution. It is clear that the responsibility lies with the graphic card.

Looking forward to hearing from you, and thank for the support.

Please boot once without nomodeset until it hangs, reboot with nomodeset, then create the log from the previous, failed boot
sudo journalctl -b -1 >journal.txt
and attach it.

Hello, thanks for helping me with the commands. Very appreciated.

I made 2 logs: one with secure boot enabled, and the other disabled. Please, find them here:
journal_secureboot-disabled.txt (172.7 KB)
journal_secureboot-enabled.txt (188.5 KB)

Looking forward to hearing from you.

I took a look at the files. It looks like the sessions where the system crashes (run without ‘nomodeset’) can’t write any log. Therefore, the files refer to the session where I used ‘nomodeset’ in any case. But you can eventually better confirm this.

You can go backwards in the logs
-b -1 means previous boot,
-b -2 the boot before that, etc.
Please check the timestamp of the logs. The video is not viewable, codec not supported.

Dear generix,

Thanks for your explanation.
I can understand that you are sceptical, therefore I followed this procedure:

Without ‘nomodeset’ and with Secureboot ON, i restarted 3 times the device. At the fourth time, I activated ‘nomodeset’ and I made 3 logs going backwards 3 times, as per your indications.
Here the related logs:
journal-secureboot_on-1.txt (179.1 KB)
journal-secureboot_on-2.txt (144.2 KB)
journal-secureboot_on-3.txt (172.7 KB)

Then, I deactivated Secureboot, and I followed the same procedure:
journal-secureboot_off-1.txt (190.3 KB)
journal-secureboot_off-2.txt (179.1 KB)
journal-secureboot_off-3.txt (144.2 KB)

Please, have a look at them. It’s like the kernel doesn’t load enough to allow any logging.

Looking forward to hearing from you.

Ernest

Then this really seems to be a critical bug in the i915 driver. Only thing you can do is upgrading the kernel to a more recent one (e.g. 5.15) than the debian 5.10 stock kernel and then check if it works.
You can leave secure boot enabled until you can boot without nomodeset as this will take the nvidia gpu out of the equation, making it easier to debug.

Thanks.