External monitor on laptop feels laggy, Prime does not seems to work

Hello,

I am using a laptop with Intel and NVIDIA GPU (Yes, I know, it is bad for Linux). I connected an external monitor to my GPU using HDMI (I also have mini DisplayPort, but don’t have a DisplayPort cable, so I can’t test).

Furthermore, I installed the proprietary drivers following the HOWTO on RPM Fusion (Howto/NVIDIA - RPM Fusion) as well as the one about Optimus. I am not sure to understand every word, but I tried to make this work and for now, my NVIDIA GPU seems to work fine, I can run program with it (Especially Unity and Unreal Engine). My issue is related to my external monitor which feels laggy, and I suppose it is related to the drivers. My monitor is 60 Hz, but it feels like less. On Windows, it does not feel as laggy.

So I also tried following this guide: How to Set Nvidia as Primary GPU on Optimus-based Laptops :: Fedora Docs. At the end of the guide, I tried to run the glxinfo command, but it output the Intel GPU instead of the NVIDIA one

nvidia-smi etc works fine, and my GPU is detected by my system and by the running apps, only the external monitor does not seem to work. So I am not sure what to do!

nvidia-smi output

neofetch output

Thanks!

Please post text from your screen as text you copy & paste using the preformatted text button </> on the tool bar.

The text is smaller than an image, is searchable (an image is not), and is easier to read for many of us.

Please post the output from mokutil --sb-state and cat /etc/X11/xorg.conf.d/nvidia.conf as well as xrandr

Sorry, I’ll post as text next time.

Btw, I’m using the default Fedora DE with GNOME and Wayland.

$ mokutil --sb-state

SecureBoot disabled

$ cat /etc/X11/xorg.conf.d/nvidia.conf

#This file is provided by xorg-x11-drv-nvidia
#Do not edit

Section "OutputClass"
	Identifier "nvidia"
	MatchDriver "nvidia-drm"
	Driver "nvidia"
	Option "AllowEmptyInitialConfiguration"
	Option "SLI" "Auto"
	Option "BaseMosaic" "on"
	Option "PrimaryGPU" "yes"
EndSection

Section "ServerLayout"
	Identifier "layout"
	Option "AllowNVIDIAGPUScreens"
EndSection

$ xrandr

Screen 0: minimum 16 x 16, current 3840 x 1313, maximum 32767 x 32767
HDMI-3 connected primary 1920x1080+1920+0 (normal left inverted right x axis y axis) 510mm x 290mm
   1920x1080     59.96*+
   1440x1080     59.99  
   1400x1050     59.98  
   1280x1024     59.89  
   1280x960      59.94  
   1152x864      59.96  
   1024x768      59.92  
   800x600       59.86  
   640x480       59.38  
   320x240       59.52  
   1680x1050     59.95  
   1440x900      59.89  
   1280x800      59.81  
   1152x720      59.97  
   960x600       59.63  
   928x580       59.88  
   800x500       59.50  
   768x480       59.90  
   720x480       59.71  
   640x400       59.95  
   320x200       58.96  
   1600x900      59.95  
   1368x768      59.88  
   1280x720      59.86  
   1024x576      59.90  
   864x486       59.92  
   720x400       59.55  
   640x350       59.77  
eDP-1 connected 1920x1080+0+233 (normal left inverted right x axis y axis) 340mm x 190mm
   1920x1080    143.88*+
   1440x1080    143.90  
   1400x1050    143.89  
   1280x1024    143.92  
   1280x960     144.00  
   1152x864     143.92  
   1024x768     143.87  
   800x600      143.83  
   640x480      143.85  
   320x240      142.05  
   1680x1050    143.97  
   1440x900     143.86  
   1280x800     143.84  
   1152x720     143.77  
   960x600      143.72  
   928x580      143.82  
   800x500      143.68  
   768x480      143.69  
   720x480      143.85  
   640x400      143.37  
   320x200      141.40  
   1600x900     143.93  
   1368x768     143.77  
   1280x720     143.85  
   1024x576     143.91  
   864x486      143.63  
   720x400      143.88  
   640x350      143.57  

Only thing I see is 2 monitors, each 1920x1080, one at 60 hz, the other at 144 hz, and combined into a single display matrix of 3840x1313.

I really would not expect that to function well.
It appears the laptop screen is driven at 16x10.94 and the external monitor is 16x9 so they are mismatched on resolution.

What happens if you change the laptop screen to 1920x1080 instead of 1920x1313 (or rather the
overall screen display to 3840x1080)?

Mmmh. That’s weird, because the Displays settings in GNOME shows both screen to be 1920x1080 (16:9).

I think that’s because I set up my monitor to have a small offset (to match how they are on my desk).

I put them on the same level, so now it is 3840x108.0, but it does not seems to solve my issue :neutral_face: