Dual GPU/Monitor; Xinerama: black screen; Nvidia 460.91.03, 470.94, 495.46

How do I set up a machine with two GPUs (GPU0 -->Screen0; GPU1 → Screen1), and being able to move windows from one screen to another?

OS: Debian 11 Stable Bullseye 64Bits

GPU0: GTX 1060 6GB → Connected via Display port to Monitor 0
GPU1: GTX 750ti 2GB → Connected via DVI to Monitor 1


I tried Xinerama by doing the following:

sudo nvidia-settings → enable Xinerama → Save to X Configuration File → Reboot

Once the reboot process is completed, both screens go black.
I have tried with the Nvidia Driver version: 460.91.03, 470.94 and 495.46

I have no such issues with Win10.

nvidia-bug-report.log.gz (458.5 KB)

You could try this:
have an xorg.conf only containing

Section "Device"
  Identifier "nvidia"
  Driver "nvidia"
  BusID "PCI:1:0:0"
  Option "PrimaryGpu" "yes"
EndSection

After reboot, only one monitor should be on, use

xrandr --listproviders

to check that two providers are available, NVIDIA-0 and NVIDIA-G0
Then run

xrandr --setprovideroutputsource NVIDIA-G0 NVIDIA-0 && xrandr --auto

and report back if the second monitor comes alive.
IMHO, a setup like this doesn’t yield any benefit but heating up your room a bit more.

Hello generix,

I created a new xorg.conf file per your instruction, I rebooted, and yes, only the primary monitor was working.

But after I executed the below command

xrandr --setprovideroutputsource NVIDIA-G0 NVIDIA-0 && xrandr --auto

I got the following

xrandr: Configure crtc 4 failed

I am not sure you need this info, but just in case

xrandr --listproviders

Providers: number : 2
Provider 0: id: 0x1b8 cap: 0x1, Source Output crtcs: 4 outputs: 7 associated providers: 1 name:NVIDIA-0
Provider 1: id: 0x379 cap: 0x2, Sink Output crtcs: 4 outputs: 5 associated providers: 1 name:NVIDIA-G0

GTX 1060 6GB → GPU0 → Primary Monitor 144hz
GTX 750Ti 2GB → GPU1 → Secondary Monitor 60hz

The reason I prefer to use two GPUs/Monitors over just one GPU0 GTX1060 → Two Screens in my case, it is because of the lag that occurs in the primary monitor. Yes, when I enable both screens, in the primary one, the entire OS’ GUI, starts lagging out even thought the screen is set to 144HZ, and this is only happening when the secondary screen is enabled and both screens are connected to a single GPU.

I have the same issue/behavior/lag in Win10 when Two Monitors are enabled in one GPU and the only way I found out to stop this “lag” is to disable the secondary screen or to use two GPUs/Monitors.

So, I was hoping to achieve the same result that I had in Win10 in Linux by using two GPUs/Monitors.

Now that’s…unfortunate. This feature was added with 470.42 according to the changelog

  • Added support for PRIME Display Offload where both the display offload
    source and display offload sink are driven by the NVIDIA X Driver.

but obviously doesn’t work reliably.
Don’t know if there are other prerequisites, e.g. regarding kernel version.

Another approach to fix the base issue might be connecting both monitors to the 1060 and setting in your system profile

export __GL_SYNC_DISPLAY_DEVICE="DFP-3"

Hello generix,
I was able to fix the lag that occurred in the primary monitor by adding in /etc/environment the following

KWIN_X11_REFRESH_RATE=144000
KWIN_X11_NO_SYNC_TO_VBLANK=1
KWIN_X11_FORCE_SOFTWARE_VSYNC=1

I am not sure is this is a X11 issue, but I am glad that I was able to find a solution.
I hope this will help someone out there.