Vanilla-OS / nvidia-image

Containerfile for the Vanilla OS Desktop+Nvidia image.
https://images.vanillaos.org/#/recipe/nvidia
GNU General Public License v3.0
8 stars 11 forks source link

[Orchid] Secondary monitor not recognized #17

Closed ParanoidNemo closed 1 month ago

ParanoidNemo commented 6 months ago

Issue Description

I've installed Orchid on my laptop (Inspiron 7577) and when I connect my external monitor via HDMI (which is directly soldered on the Nvidia card) the monitor doesn't work (no signal).

Steps to Reproduce

On what version of Vanilla OS this happens?

Unreleased

Additional Information

nvidia-smi

Sun Feb 11 13:19:07 2024       
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 525.147.05   Driver Version: 525.147.05   CUDA Version: 12.0     |
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|                               |                      |               MIG M. |
|===============================+======================+======================|
|   0  NVIDIA GeForce ...  On   | 00000000:01:00.0 Off |                  N/A |
| N/A   47C    P5     7W /  60W |      3MiB /  6144MiB |      0%      Default |
|                               |                      |                  N/A |
+-------------------------------+----------------------+----------------------+

+-----------------------------------------------------------------------------+
| Processes:                                                                  |
|  GPU   GI   CI        PID   Type   Process name                  GPU Memory |
|        ID   ID                                                   Usage      |
|=============================================================================|
+-----------------------------------------------------------------------------+

cur-gpu

OpenGL version: 4.6 (Compatibility Profile) Mesa 23.3.4-1
OpenGL vendor: Intel
OpenGL renderer: Mesa Intel(R) HD Graphics 630 (KBL GT2)

nrun cur-gpu

OpenGL version: 4.6 (Compatibility Profile) Mesa 23.3.4-1
OpenGL vendor: Intel
OpenGL renderer: Mesa Intel(R) HD Graphics 630 (KBL GT2)

In general drivers seems to be installed correctly because, for example Blender, can render using the Nvidia GPU. I think the problem is directly related to VanillaOS because before installing Orchid on this laptop I was using Debian 12 with Nvidia drivers only and the secondary monitor didn't have any problem.

MeowRosya commented 1 month ago

Same problem in a hybrid mode on laptop with AMD CPU and Nvidia GPU and proprietary driver installed (555.42.x). The second monitor was recognized and worked via HDMI only during installation, after the first reboot it no longer worked. Only thing that helped was switching to discrete mode in UEFI, when both screens are using the Nvidia GPU. AMD Ryzen 7 5800H + NVIDIA RTX 3070 Laptop GPU

mirkobrombin commented 1 month ago

Can you try setting this kflag via abroot nvidia.NVreg_EnableGpuFirmware=0 then restart?

MeowRosya commented 1 month ago

Adding only nvidia.NVreg_EnableGpuFirmware=0 to the kernel parameter didn't help at all. But additionally adding nvidia_drm.modeset=1 solved the problem and now the second monitor is recognized and works without problems. Thanks!!

It broke gdm if use discrete graphics mode, but I already knew that modeset will break login screen and GNOME, so I was prepared for it. Also, Mission Center and nvtop told me that the video card was used at 40%, although it did not perform any tasks and I just rebooted. I add nvidia.NVreg_PreserveVideoMemoryAllocations=1 and the problem was gone.

asdreemurr844 commented 1 month ago

i have the same thing on the MSI Bravo C7VE, NVIDIA GeForce RTX 4050. I've tried to add kargs, but it doesn't help.

nvidia-smi

+-----------------------------------------------------------------------------------------+
| NVIDIA-SMI 560.28.03              Driver Version: 560.28.03      CUDA Version: 12.6     |
|-----------------------------------------+------------------------+----------------------+
| GPU  Name                 Persistence-M | Bus-Id          Disp.A | Volatile Uncorr. ECC |
| Fan  Temp   Perf          Pwr:Usage/Cap |           Memory-Usage | GPU-Util  Compute M. |
|                                         |                        |               MIG M. |
|=========================================+========================+======================|
|   0  NVIDIA GeForce RTX 4050 ...    Off |   00000000:01:00.0 Off |                  N/A |
| N/A   54C    P0             17W /   80W |       1MiB /   6141MiB |      0%      Default |
|                                         |                        |                  N/A |
+-----------------------------------------+------------------------+----------------------+

+-----------------------------------------------------------------------------------------+
| Processes:                                                                              |
|  GPU   GI   CI        PID   Type   Process name                              GPU Memory |
|        ID   ID                                                               Usage      |
|=========================================================================================|
|  No running processes found                                                             |
+-----------------------------------------------------------------------------------------+

cur-gpu

OpenGL version: 4.6 (Compatibility Profile) Mesa 24.1.3-2
OpenGL vendor: AMD
OpenGL renderer: AMD Radeon 680M (radeonsi, rembrandt, LLVM 17.0.6, DRM 3.57, 6.9.8-amd64)

nrun cur-gpu

OpenGL version: 4.6.0 NVIDIA 560.28.03
OpenGL vendor: NVIDIA Corporation
OpenGL renderer: NVIDIA GeForce RTX 4050 Laptop GPU/PCIe/SSE2
mirkobrombin commented 1 month ago

Some users with recent GPUs fixed by upgrading to the latest nvidia image, some other with older GPUs fixed by moving to the nvidia-proprietary image.

Please have a read: https://docs.vanillaos.org/handbook/en/nvidia-issues

Also be sure to cleanup your kernel arguments before trying a new image.

asdreemurr844 commented 1 month ago

changing images doesn't helped too :(

mirkobrombin commented 1 month ago

I just published an update in both images that could fix it (automatically or manually setting the modeset karg), will be available in ~30 minutes

asdreemurr844 commented 1 month ago

works with discrete gpu mode PXL_20240803_111611451.RAW-01.COVER.jpg