Nvidia screen tearing on ASUS TUF Gaming laptop

So, I’ve been using Manjaro for a while and recently got a new laptop with Nvidia graphics card. The laptop has 2 disks and Manjaro and Windows live on different ones. I’ve disabled fast-start on Windows.

System information:

System:
  Kernel: 5.15.74-3-MANJARO arch: x86_64 bits: 64 compiler: gcc v: 12.2.0
    parameters: BOOT_IMAGE=/boot/vmlinuz-5.15-x86_64
    root=UUID=7818ce07-73a7-4f48-a495-ff151a0c35eb rw
    cryptdevice=UUID=41b5b13b-ff4d-48d9-b2c0-d80d3d3b9fe9:luks-41b5b13b-ff4d-48d9-b2c0-d80d3d3b9fe9
    root=/dev/mapper/luks-41b5b13b-ff4d-48d9-b2c0-d80d3d3b9fe9
    udev.log_priority=3 ibt=off
  Desktop: KDE Plasma v: 5.25.5 tk: Qt v: 5.15.6 wm: kwin_x11 vt: 1 dm: SDDM
    Distro: Manjaro Linux base: Arch Linux
Machine:
  Type: Laptop System: ASUSTeK product: ASUS TUF Gaming F15 FX507ZE_FX577ZE
    v: 1.0 serial: <superuser required>
  Mobo: ASUSTeK model: FX507ZE v: 1.0 serial: <superuser required>
    UEFI: American Megatrends LLC. v: FX507ZE.315 date: 06/17/2022
Battery:
  ID-1: BAT1 charge: 35.3 Wh (38.2%) condition: 92.4/90.2 Wh (102.4%)
    volts: 14.9 min: 15.9 model: ASUS A32-K55 type: Li-ion serial: N/A
    status: discharging
CPU:
  Info: 14-core (6-mt/8-st) 12th Gen Intel Core i7-12700H [MST AMCP]
    arch: Alder Lake speed (MHz): avg: 498 min/max: 400/4679:4700:3500
Graphics:
  Device-1: Intel Alder Lake-P Integrated Graphics vendor: ASUSTeK
    driver: i915 v: kernel arch: Gen-12.2 process: Intel 10nm built: 2021-22+
    ports: active: eDP-1 empty: DP-1,DP-2 bus-ID: 0000:00:02.0
    chip-ID: 8086:46a6 class-ID: 0300
  Device-2: NVIDIA GA107M [GeForce RTX 3050 Ti Mobile] vendor: ASUSTeK
    driver: nvidia v: 520.56.06 alternate: nouveau,nvidia_drm non-free: 515.xx+
    status: current (as of 2022-10) arch: Ampere code: GAxxx process: TSMC n7
    (7nm) built: 2020-22 bus-ID: 0000:01:00.0 chip-ID: 10de:25a0
    class-ID: 0300
  Device-3: Sonix USB2.0 HD UVC WebCam type: USB driver: uvcvideo
    bus-ID: 3-7:2 chip-ID: 322e:202c class-ID: 0e02
  Display: x11 server: X.Org v: 21.1.4 compositor: kwin_x11 driver: X:
    loaded: modesetting,nvidia alternate: fbdev,nouveau,nv,vesa dri: iris
    gpu: i915 resolution: 1920x1080~144Hz
  OpenGL: renderer: Mesa Intel Graphics (ADL GT2) v: 4.6 Mesa 22.1.7
    direct render: Yes
Network:
  Device-1: Intel Alder Lake-P PCH CNVi WiFi driver: iwlwifi v: kernel
    bus-ID: 0000:00:14.3 chip-ID: 8086:51f0 class-ID: 0280
  Device-2: Intel Ethernet I219-LM vendor: ASUSTeK driver: e1000e v: kernel
    port: N/A bus-ID: 0000:00:1f.6 chip-ID: 8086:1a1e class-ID: 0200
Drives:
  Local Storage: total: 1.38 TiB used: 19.83 GiB (1.4%)
Info:
  Processes: 406 Uptime: 16m wakeups: 1111 Memory: 15.25 GiB used: 2.82 GiB
  (18.5%) Init: systemd v: 251 default: graphical tool: systemctl Compilers:
  gcc: 12.2.0 clang: 14.0.6 Packages: 1326 pm: pacman pkgs: 1314 libs: 327
  tools: pamac pm: flatpak pkgs: 12 Shell: fish v: 3.5.1 running-in: konsole
  inxi: 3.3.22

During installation I chose “boot with proprietary drivers” and everything seems to have been installed correctly.


 ~  mhwd -li                                                                                                                                                                                               1950ms
> Installed PCI configs:
--------------------------------------------------------------------------------
                  NAME               VERSION          FREEDRIVER           TYPE
--------------------------------------------------------------------------------
video-hybrid-intel-nvidia-prime            2021.11.04               false            PCI
     video-modesetting            2020.01.13                true            PCI


Warning: No installed USB configs!
 ~  mhwd -l                                                                                                                                                                                                1861ms
> 0000:01:00.0 (0300:10de:25a0) Display controller nVidia Corporation:
--------------------------------------------------------------------------------
                  NAME               VERSION          FREEDRIVER           TYPE
--------------------------------------------------------------------------------
video-hybrid-intel-nvidia-prime            2021.11.04               false            PCI
video-hybrid-intel-nvidia-470xx-prime            2021.11.04               false            PCI
          video-nvidia            2021.11.04               false            PCI
    video-nvidia-470xx            2021.11.04               false            PCI
           video-linux            2018.05.04                true            PCI
     video-modesetting            2020.01.13                true            PCI
            video-vesa            2017.03.12                true            PCI


> 0000:00:02.0 (0300:8086:46a6) Display controller Intel Corporation:
--------------------------------------------------------------------------------
                  NAME               VERSION          FREEDRIVER           TYPE
--------------------------------------------------------------------------------
video-hybrid-intel-nvidia-prime            2021.11.04               false            PCI
video-hybrid-intel-nvidia-470xx-prime            2021.11.04               false            PCI
           video-linux            2018.05.04                true            PCI
     video-modesetting            2020.01.13                true            PCI
            video-vesa            2017.03.12                true            PCI

 ~  glxinfo | grep "OpenGL renderer"                                                                                                                                                                        624ms
OpenGL renderer string: Mesa Intel(R) Graphics (ADL GT2)
 ~  prime-run glxinfo | grep "OpenGL renderer"                                                                                                                                                              113ms
OpenGL renderer string: NVIDIA GeForce RTX 3050 Ti Laptop GPU/PCIe/SSE2
 

Issue that I have is that there is a lot of screen tearing and “glitches” that take place. I looked through the forum and wiki but my Nvidia X server settings manager don’t seem to have the options that are listed in the wiki or the forum solutions.

I use the laptop screen 1920x1080 144Hz + external monitor 1920x1080 60Hz. And sometimes only the external monitor with the laptop screen off (in case this makes a difference in how configuration should be approached).

Appreciate it if you could point me in the right direction.

Hi @wpkg,

Have a look here:

https://wiki.archlinux.org/title/NVIDIA/Troubleshooting#Avoid_screen_tearing

Thank you, however running the first command returns the following. Hence my suspicion whether the settings manager was properly configured or not.

 ~  nvidia-settings --assign CurrentMetaMode="nvidia-auto-select +0+0 { ForceFullCompositionPipeline = On }"                                                                                               1275ms


ERROR: Error resolving target specification '' (No targets match target specification), specified in assignment 'CurrentMetaMode=nvidia-auto-select +0+0 { ForceFullCompositionPipeline = On }'.


Hmmm…OK, that’s officially above my paygrade.

I could quickly find this:

https://wiki.archlinux.org/title/Intel_graphics#Tearing

If that doesn’t work, sorry I have no idea.

Unfortunately, using that conf file with the following configurations causes the boot process to get stuck on reached graphical.target and sddm does not start up. I switched to virtual terminal and deleted that file.

/etc/X11/xorg.conf.d/20-intel.conf

Section "Device"
  Identifier "Intel Graphics"
  Driver "intel"
  Option "TearFree" "true"
EndSection

OR

/etc/X11/xorg.conf.d/20-intel.conf

Section "Device"
  Identifier "Intel Graphics"
  Driver "intel"
  Option "TearFree" "true"
  Option "TripleBuffer" "true"
EndSection

Thanks for trying to help, hopefully someone else has more ideas on things to try.

1 Like

you have a new hardware, so try a newer kernel, like the 5.19 - not the rt one, and the 6.0 kernel from system settings/kernel

This was my first thought as well and tried kernel 6 a couple days ago. Had the same screen tearing experience. So removed it and switched back to the LTS one before posting on the forum.

However, you make a fair point. I’ve switched to Linux wrapper 6.0.2-2-MANJARO #1 SMP PREEMPT_DYNAMIC Sat Oct 15 13:31:58 UTC 2022 x86_64 GNU/Linux now.

My “Nvidia settings” does not have anything for me to change, its mostly just information such as driver version etc. Is that how it looks for others as well (This is the first time that I’ve bought a laptop with Nvidia, hence all the questions)?.

your nvidia settings dont have any options there because you are now running in hybrid mode, which means you are on your intel gpu and nvidia is ‘dormant’ … so its very likely that the screen tearing is not related to nvidia, but who knows… i would suggest to install optimus manager to switch between gpus:
edit your sddm.conf:
kate /etc/sddm.conf
and put a # before the line starting with DisplayCommand and the one starting with DisplayStopCommand - you may not have these display command lines there, so proceed with install:
sudo pacman -S optimus-manager optimus-manager-plasma
reboot and check if it helped with the tearing…if not switch to intel only via the optimus tray gui, it will log you out/log in and test if the screen tear is present… if yes its not related to nvidia … if its not present, switch to nvidia and test if its present there… in nvidia mode you will have now more options in your nvidia settings

1 Like

This seems to cause SDDM to malfunction.

I commented out DisplayCommand & DisplayStopCommand in /etc/sddm.conf, installed the 2 packages and rebooted. Journalctl shows the following for sddm.service

Oct 19 23:23:54 wrapper systemd[1]: Started Simple Desktop Display Manager.
Oct 19 23:23:54 wrapper sddm[667]: Initializing...
Oct 19 23:23:54 wrapper sddm[667]: Starting...
Oct 19 23:23:54 wrapper sddm[667]: Logind interface found
Oct 19 23:23:58 wrapper sddm[667]: Adding new display on vt 1 ...
Oct 19 23:23:58 wrapper sddm[667]: Loading theme configuration from ""
Oct 19 23:23:58 wrapper sddm[667]: Display server starting...
Oct 19 23:23:58 wrapper sddm[667]: Adding cookie to "/var/run/sddm/{a5a1f6bb-2097-4a0c-b6b0-9d104e6b8ac8}"
Oct 19 23:23:58 wrapper sddm[667]: Running: /usr/bin/X -nolisten tcp -background none -seat seat0 vt1 -auth /var/run/sddm/{a5a1f6bb-2097-4a0c-b6b0-9d104e6b8ac8} -noreset -displayfd 17
Oct 19 23:23:59 wrapper sddm[667]: Failed to read display number from pipe
Oct 19 23:23:59 wrapper sddm[667]: Display server stopping...
Oct 19 23:23:59 wrapper sddm[667]: Attempt 1 starting the Display server on vt 1 failed
Oct 19 23:24:01 wrapper sddm[667]: Display server starting...
Oct 19 23:24:01 wrapper sddm[667]: Adding cookie to "/var/run/sddm/{a5a1f6bb-2097-4a0c-b6b0-9d104e6b8ac8}"
Oct 19 23:24:01 wrapper sddm[667]: Running: /usr/bin/X -nolisten tcp -background none -seat seat0 vt1 -auth /var/run/sddm/{a5a1f6bb-2097-4a0c-b6b0-9d104e6b8ac8} -noreset -displayfd 17
Oct 19 23:24:01 wrapper sddm[667]: Failed to read display number from pipe
Oct 19 23:24:01 wrapper sddm[667]: Display server stopping...
Oct 19 23:24:01 wrapper sddm[667]: Attempt 2 starting the Display server on vt 1 failed
Oct 19 23:24:03 wrapper sddm[667]: Display server starting...
Oct 19 23:24:03 wrapper sddm[667]: Adding cookie to "/var/run/sddm/{a5a1f6bb-2097-4a0c-b6b0-9d104e6b8ac8}"
Oct 19 23:24:03 wrapper sddm[667]: Running: /usr/bin/X -nolisten tcp -background none -seat seat0 vt1 -auth /var/run/sddm/{a5a1f6bb-2097-4a0c-b6b0-9d104e6b8ac8} -noreset -displayfd 17
Oct 19 23:24:03 wrapper sddm[667]: Failed to read display number from pipe
Oct 19 23:24:03 wrapper sddm[667]: Display server stopping...
Oct 19 23:24:03 wrapper sddm[667]: Attempt 3 starting the Display server on vt 1 failed
Oct 19 23:24:03 wrapper sddm[667]: Could not start Display server on vt 1
Oct 19 23:26:21 wrapper systemd[1]: Stopping Simple Desktop Display Manager...
Oct 19 23:26:21 wrapper sddm[667]: Signal received: SIGTERM
Oct 19 23:26:21 wrapper systemd[1]: sddm.service: Deactivated successfully.
Oct 19 23:26:21 wrapper systemd[1]: Stopped Simple Desktop Display Manager.

Logged into VT2 removed optimus-manager, optimus-manager-plasma, removed comments in /etc/sddm.conf and rebooted to get a working system. Are there any steps I may have missed?

so you had actually the comments there in the sddm.conf?
and edited them to look like this:
#DisplayCommand
#DisplayStopCommand
and optimus doesnt support wayland

Correct. And I understand regarding wayland. I’m on x11.

~  echo $XDG_SESSION_TYPE
x11

My full sddm.conf file if it helps:

[Autologin]
Relogin=false
Session=plasma

[General]
HaltCommand=/usr/bin/systemctl poweroff
InputMethod=
Numlock=none
RebootCommand=/usr/bin/systemctl reboot

[Theme]
Current=breath
CursorTheme=breeze_cursors
DisableAvatarsThreshold=7
EnableAvatars=true
FacesDir=/usr/share/sddm/faces
ThemeDir=/usr/share/sddm/themes

[Users]
DefaultPath=/usr/local/sbin:/usr/local/bin:/usr/bin
HideShells=
HideUsers=
MaximumUid=60000
MinimumUid=1000
RememberLastSession=true
RememberLastUser=true
ReuseSession=false

[Wayland]
EnableHiDPI=false
SessionCommand=/usr/share/sddm/scripts/wayland-session
SessionDir=/usr/share/wayland-sessions
SessionLogFile=.local/share/sddm/wayland-session.log

[X11]
DisplayCommand=/usr/share/sddm/scripts/Xsetup
DisplayStopCommand=/usr/share/sddm/scripts/Xstop
EnableHiDPI=false
MinimumVT=1
ServerArguments=-nolisten tcp
ServerPath=/usr/bin/X
SessionCommand=/usr/share/sddm/scripts/Xsession
SessionDir=/usr/share/xsessions
SessionLogFile=.local/share/sddm/xorg-session.log
UserAuthFile=.Xauthority
XauthPath=/usr/bin/xauth
XephyrPath=/usr/bin/Xephyr


/usr/share/sddm/scripts/Xsetup is empty by the way.

so dont know why it didnt worked… did you tried booting also with the 5.15 kernel?
also check if there is some leftover optimus conf:
find /etc/X11/ -name "*.conf"
if yes remove it, and install this:
pamac build envycontrol
its another gpu switching tool… when its installed run this:
sudo envycontrol -s integrated
it will prompt you for a reboot, so do it and see if there is tearing on only intel one, if its not, switch to nvidia:
sudo envycontrol -s nvidia
reboot and see if the tearing is present here

I forgot about the 515 kernel after installing optimus. I should try that. I think there are some changes made in the kernel after 518 that causes Nvidia drivers to break if we don’t use ibt=off as a kernel parameter. I’ve been using that. That might have some impact on optimus working or not on the 6 kernel.

I’ll also try envy control and respond back here.

 ~  find /etc/X11/ -name "*.conf"
/etc/X11/mhwd.d/nvidia.conf
/etc/X11/xorg.conf.d/30-touchpad.conf
/etc/X11/xorg.conf.d/00-keyboard.conf
/etc/X11/xorg.conf
 ~  

I think these are “safe” files to keep.

the ibt parameter is not the reason why it didnt worked…
no optimus leftovers, but you have there xorg.conf, did you added it there?

I think it came with the installation. It’s empty. Same with /etc/X11/mhwd.d/nvidia.conf which contains a comment about being installed by Manjaro hardware manager.

the xorg shouldnt be there, but since its empty, proceed with the envycontrol…

Hey, I had a similar experience with my laptop, I have an ACER laptop with an integrated (in my case AMD) GPU and a dedicated Nvidia GPU 1650 Mobile. I had problems with screen tearing for a while now, mostly when running games through Wine or Bottles (Games ran with Proton for some reason didn’t trigger the screen tearing issue) and the only solution I found was switching from X11 to Wayland.
I tried Optimus Manager but it had some strange side effects which when I switched to only the dedicated GPU the games would run like 50% faster, making them unplayable. I’m not particularly skilled with Linux yet, so I ditched Optimus Manager in favor of Wayland and so far my experience is way smoother compared to X11. I’m currently running GNOME and I followed this guide to activate the Wayland session since it doesn’t come active by default: https://forum.manjaro.org/t/howto-use-wayland-with-proprietary-nvidia-drivers/36130
I suggest you give Wayland a shot, you can always switch back to X if it doesn’t work for you.

Yep, tried switching to wayland, but its got its own set of issues (no maximize/minimize buttons for flatpak applications, kwin_wayland consuming 2% of CPU which seems strange, strange freezes etc.).

But that might have been because I’m on Plasma, I suspect GNOME is more feature rich on the Wayland side.

Using a newer kernel was the right approach (I’ve not been ignoring this thread, just switched to a newer kernel and let it run for a couple months to be sure). I’ve been with 6.1 for a while now and it’s working well.

But, I’ve run into other issues (will post on a new thread as this one was for screen tearing), dead slow 1 FPS external screen, workaround for which is to use reverse-prime - PRIME - ArchWiki

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.