Blank screen after update - nv driver reinstall helps only until reboot

Hi fellow nerds! A noobish problem which I couldn’t solve on my own or using existing answers.

My tl; dr problem is having a black screen, right after boot and disk decryption which can be temporarily mitigated following the steps listed by @Fabby in “Blank screen after update. (Xorg: No devices/screens found.” thread. After a reboot everything seems to go back to a bad state - I can’t just startx, gotta do the full reinstall, just as described in the post mentioned above, and just then startx.

Full description:
I was on 5.14 (trying to mitigate some unrelated wifi issues), got a bunch of updates, updated and ended up with a blank screen after boot issue. My setup was a dual gpu one, with optimus manager handling which gpu to use. I had it set up so that the integrated graphics were used when booting on battery and nv was selected when booting while plugged it, it was working without issues.

What I already did:

  • downgraded my kernel to 5.10
  • removed other kernels (mhwd was getting lost with more than one present)
  • reinstalled video drivers like 100 times (sudo mhwd --remove pci video-hybrid-intel-nvidia-prime, sudo mhwd --install pci video-hybrid-intel-nvidia-prime and similar)
  • made sure everything else is up to date
  • removed some dependencies preventing me from removing the nv driver, including the optimus manager which now I can’t reinstall:
❯ sudo pacman -R optimus-manager
[sudo] password for artur: 
checking dependencies...
error: failed to prepare transaction (could not satisfy dependencies)
:: removing optimus-manager breaks dependency 'optimus-manager>=1.4' required by optimus-manager-qt
❯ sudo pacman -S optimus-manager
error: target not found: optimus-manager

Forgive me for being a noob, I’m not sure which logs would be useful to include. I’ll happily provide any more info needed, just please let me know what would be useful.

Thanks!

can you provide

inxi -Fza 
sudo mhwd -li
sudo mhwd-kernel -li 

you should keep theses kernels versions

  • 510 ( LTS ) , 515 (LTS )

version 5.14 is EOL

Sure, thank you for your quick response @stephane :slight_smile:

❯ inxi -Fza
System:
  Kernel: 5.10.89-1-MANJARO x86_64 bits: 64 compiler: gcc v: 11.1.0
    parameters: BOOT_IMAGE=/boot/vmlinuz-5.10-x86_64
    root=UUID=9c52b7fc-b63b-40c8-972f-8634e63d1e11 ro quiet
    cryptdevice=UUID=53013d51-8639-4ce5-92f3-bf4725fdb8f7:luks-53013d51-8639-4ce5-92f3-bf4725fdb8f7
    root=/dev/mapper/luks-53013d51-8639-4ce5-92f3-bf4725fdb8f7 apparmor=1
    security=apparmor udev.log_priority=3
  Desktop: KDE Plasma 5.23.4 tk: Qt 5.15.2 wm: kwin_x11 vt: 2
    dm: GDM 41.0, SDDM Distro: Manjaro Linux base: Arch Linux
Machine:
  Type: Laptop System: Dell product: XPS 15 9500 v: N/A
    serial: <superuser required> Chassis: type: 10 serial: <superuser required>
  Mobo: Dell model: 05XYW7 v: A00 serial: <superuser required> UEFI: Dell
    v: 1.6.1 date: 12/24/2020
Battery:
  ID-1: BAT0 charge: 61.1 Wh (100.0%) condition: 61.1/84.3 Wh (72.5%)
    volts: 12.6 min: 11.4 model: BYD DELL M59JH05 type: Li-poly
    serial: <filter> status: Full
CPU:
  Info: model: Intel Core i7-10750H bits: 64 type: MT MCP arch: Comet Lake
    family: 6 model-id: 0xA5 (165) stepping: 2 microcode: 0xEA
  Topology: cpus: 1x cores: 6 tpc: 2 threads: 12 smt: enabled cache:
    L1: 384 KiB desc: d-6x32 KiB; i-6x32 KiB L2: 1.5 MiB desc: 6x256 KiB
    L3: 12 MiB desc: 1x12 MiB
  Speed (MHz): avg: 3160 high: 3200 min/max: 800/5000 scaling:
    driver: intel_pstate governor: powersave cores: 1: 3100 2: 3199 3: 3195
    4: 3101 5: 3184 6: 3200 7: 3155 8: 3192 9: 3120 10: 3115 11: 3182
    12: 3187 bogomips: 62431
  Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx
  Vulnerabilities:
  Type: itlb_multihit status: KVM: VMX disabled
  Type: l1tf status: Not affected
  Type: mds status: Not affected
  Type: meltdown status: Not affected
  Type: spec_store_bypass
    mitigation: Speculative Store Bypass disabled via prctl and seccomp
  Type: spectre_v1
    mitigation: usercopy/swapgs barriers and __user pointer sanitization
  Type: spectre_v2
    mitigation: Enhanced IBRS, IBPB: conditional, RSB filling
  Type: srbds status: Not affected
  Type: tsx_async_abort status: Not affected
Graphics:
  Device-1: Intel CometLake-H GT2 [UHD Graphics] vendor: Dell driver: i915
    v: kernel bus-ID: 00:02.0 chip-ID: 8086:9bc4 class-ID: 0300
  Device-2: NVIDIA TU117M [GeForce GTX 1650 Ti Mobile] vendor: Dell
    driver: nvidia v: 495.44 alternate: nouveau,nvidia_drm bus-ID: 01:00.0
    chip-ID: 10de:1f95 class-ID: 0302
  Device-3: Microdia Integrated_Webcam_HD type: USB driver: uvcvideo
    bus-ID: 1-11:3 chip-ID: 0c45:6d14 class-ID: 0e02
  Display: server: X.Org 1.21.1.2 compositor: kwin_x11 driver:
    loaded: modesetting,nvidia display-ID: :0 screens: 1
  Screen-1: 0 s-res: 1920x1200 s-dpi: 75 s-size: 652x407mm (25.7x16.0")
    s-diag: 769mm (30.3")
  Monitor-1: eDP-1-1 res: 1920x1200 dpi: 145 size: 336x210mm (13.2x8.3")
    diag: 396mm (15.6")
  OpenGL: renderer: NVIDIA GeForce GTX 1650 Ti/PCIe/SSE2
    v: 4.6.0 NVIDIA 495.44 direct render: Yes
Audio:
  Device-1: Intel Comet Lake PCH cAVS vendor: Dell driver: snd_hda_intel
    v: kernel alternate: snd_soc_skl,snd_sof_pci bus-ID: 00:1f.3
    chip-ID: 8086:06c8 class-ID: 0403
  Sound Server-1: ALSA v: k5.10.89-1-MANJARO running: yes
  Sound Server-2: JACK v: 1.9.19 running: no
  Sound Server-3: PulseAudio v: 15.0 running: yes
  Sound Server-4: PipeWire v: 0.3.42 running: yes
Network:
  Device-1: Intel Comet Lake PCH CNVi WiFi vendor: Rivet Networks
    driver: iwlwifi v: kernel bus-ID: 00:14.3 chip-ID: 8086:06f0 class-ID: 0280
  IF: wlp0s20f3 state: up mac: <filter>
Bluetooth:
  Device-1: Intel AX201 Bluetooth type: USB driver: btusb v: 0.8
    bus-ID: 1-14:4 chip-ID: 8087:0026 class-ID: e001
  Report: rfkill ID: hci0 rfk-id: 1 state: up address: see --recommends
Drives:
  Local Storage: total: 931.51 GiB used: 65.48 GiB (7.0%)
  SMART Message: Unable to run smartctl. Root privileges required.
  ID-1: /dev/nvme0n1 maj-min: 259:0 vendor: Kingston model: SA2000M81000G
    size: 931.51 GiB block-size: physical: 512 B logical: 512 B
    speed: 31.6 Gb/s lanes: 4 type: SSD serial: <filter> rev: S5Z42105
    temp: 28.9 C scheme: GPT
Partition:
  ID-1: / raw-size: 931.21 GiB size: 915.6 GiB (98.32%)
    used: 65.43 GiB (7.1%) fs: ext4 dev: /dev/dm-0 maj-min: 254:0
    mapped: luks-53013d51-8639-4ce5-92f3-bf4725fdb8f7
  ID-2: /boot/efi raw-size: 300 MiB size: 299.4 MiB (99.80%)
    used: 45.7 MiB (15.3%) fs: vfat dev: /dev/nvme0n1p1 maj-min: 259:1
Swap:
  Kernel: swappiness: 60 (default) cache-pressure: 100 (default)
  ID-1: swap-1 type: file size: 512 MiB used: 0 KiB (0.0%) priority: -2
    file: /swapfile
Sensors:
  System Temperatures: cpu: 82.0 C pch: 60.0 C mobo: N/A gpu: nvidia
    temp: 74 C
  Fan Speeds (RPM): cpu: 5423 mobo: 5690 fan-2:
Info:
  Processes: 385 Uptime: 50m wakeups: 12414 Memory: 31.1 GiB
  used: 16.25 GiB (52.3%) Init: systemd v: 250 tool: systemctl Compilers:
  gcc: 11.1.0 alt: 10 clang: 13.0.0 Packages: 1530 pacman: 1528 lib: 442
  flatpak: 0 snap: 2 Shell: Zsh v: 5.8 running-in: yakuake inxi: 3.3.11

❯ sudo mhwd -li
> Installed PCI configs:
--------------------------------------------------------------------------------
                  NAME               VERSION          FREEDRIVER           TYPE
--------------------------------------------------------------------------------
     video-modesetting            2020.01.13                true            PCI
video-hybrid-intel-nvidia-prime            2021.12.18               false            PCI


Warning: No installed USB configs!
❯ sudo mhwd-kernel -li
Currently running: 5.10.89-1-MANJARO (linux510)
The following kernels are installed in your system:
   * linux510

‘Optimus manager’ was removed from the repos mentioned here:

can you check

sudo journalctl -b0 -g nvidia

But it does seem to be in the AUR:

According to @stephane , not anymore
$ pamac search optimus-manager
[...]
optimus-manager                                                                                                                                                                                                                   1.4-3                 AUR
Management utility to handle GPU switching for Optimus laptops

$ pamac info optimus-manager
Name                  : optimus-manager
Version               : 1.4-3
Description           : Management utility to handle GPU switching for Optimus laptops
URL                   : https://github.com/Askannz/optimus-manager
Licences              : MIT
Repository            : AUR
Depends On            : python3 python-setuptools python-dbus mesa-demos xorg-xrandr
Optional Dependencies : bbswitch
acpi_call
xf86-video-intel
Make Dependencies     : python-setuptools git
Provides              : optimus-manager=1.4
Conflicts With        : optimus-manager-git
Maintainer            : Askannz
First Submitted       : 17/11/2018
Last Modified         : 14/12/2021
Votes                 : 100

(And that’s all I know, don’t have a use for it nor do I really know what it’s for except something to do with laptop graphics.)

no more in AUR , alos version python was on 3.9 , and this is broken with 3.10

@stephane

❯ sudo journalctl -b0 -g nvidia
[sudo] password for artur: 
sty 07 11:53:29 artur-xps159500 audit[348]: AVC apparmor="STATUS" operation="profile_load" profile="unconfined" name="nvidia_modprobe" pid=348 comm="apparmor_parser"
sty 07 11:53:29 artur-xps159500 audit[348]: AVC apparmor="STATUS" operation="profile_load" profile="unconfined" name="nvidia_modprobe//kmod" pid=348 comm="apparmor_parser"
sty 07 11:53:51 artur-xps159500 dbus-daemon[674]: [system] Activating via systemd: service name='org.freedesktop.home1' unit='dbus-org.freedesktop.home1.service' requested by ':1.27' (uid=0 pid=1096 comm="sudo m>
sty 07 11:53:54 artur-xps159500 sudo[1096]:    artur : TTY=tty2 ; PWD=/home/artur ; USER=root ; COMMAND=/usr/bin/mhwd --install pci video-hybrid-intel-nvidia-prime
sty 07 11:54:19 artur-xps159500 kernel: nvidia: loading out-of-tree module taints kernel.
sty 07 11:54:19 artur-xps159500 kernel: nvidia: module license 'NVIDIA' taints kernel.
sty 07 11:54:19 artur-xps159500 kernel: nvidia: module verification failed: signature and/or required key missing - tainting kernel
sty 07 11:54:19 artur-xps159500 kernel: nvidia-nvlink: Nvlink Core is being initialized, major device number 509
sty 07 11:54:19 artur-xps159500 kernel: nvidia 0000:01:00.0: enabling device (0000 -> 0003)
sty 07 11:54:20 artur-xps159500 kernel: NVRM: loading NVIDIA UNIX x86_64 Kernel Module  495.44  Fri Oct 22 06:13:12 UTC 2021
sty 07 11:54:20 artur-xps159500 kernel: nvidia-modeset: Loading NVIDIA Kernel Mode Setting Driver for UNIX platforms  495.44  Fri Oct 22 06:05:22 UTC 2021
sty 07 11:54:20 artur-xps159500 kernel: [drm] [nvidia-drm] [GPU ID 0x00000100] Loading driver
sty 07 11:54:20 artur-xps159500 kernel: [drm] Initialized nvidia-drm 0.0.0 20160202 for 0000:01:00.0 on minor 1
sty 07 11:54:38 artur-xps159500 dbus-daemon[4839]: [session uid=1000 pid=4837] Activating service name='org.a11y.Bus' requested by ':1.50' (uid=1000 pid=5343 comm="/usr/bin/nvidia-settings -q=GPUUtilization -t ")
sty 07 15:39:50 artur-xps159500 dbus-daemon[674]: [system] Activating via systemd: service name='org.freedesktop.home1' unit='dbus-org.freedesktop.home1.service' requested by ':1.182' (uid=0 pid=42627 comm="sudo>
sty 07 15:39:52 artur-xps159500 sudo[42627]:    artur : TTY=pts/1 ; PWD=/home/artur ; USER=root ; COMMAND=/usr/bin/journalctl -b0 -g nvidia

Regarding optimus-manager, do you guys know if there’s an alternative way of switching GPUs then? Or do all dual GPU users now need to decide on either one?

I believe you’'d have to run the applications youwish to use the Dedicated graphics with prime-run for nVidia and DRI_PRIME=1 for AMD. But I’m no expert and might be wrong.

Any ideas what else I could try folks?

Halo, i have the same issue, and have it fixed it. Here is what i do:
uninstall optimus manager and optimus manager qt if u have it

sudo pacman -R optimus-manager-qt
sudo pacman -R optimus-manager 

reinstall nvidia (i dont know if this matter)

sudo mhwd --remove pci video-hybrid-intel-nvidia-prime
sudo mhwd -a pci nonfree 0300

and then reboot, edit the boot option on grub by pressing e. add option to disable nvidia (also dont know if this matter, havent try with the nvidia on), by adding this option after quite (seperate by whitespace)

nvidia.modeset=0 nouveau.modeset=0

Wow @SKey, thank you internet stranger! It seems that all my problems boiled down to optimus-manager. I followed your advice to remove optimus-manager and reinstall nv driver. The system booted all the way up to the desktop without modifying grub options in intel graphics mode.

While without optimus-manager I can’t run the system in full NV mode (or I didn’t figure it out yet), I can run individual binaries with

__NV_PRIME_RENDER_OFFLOAD=1 __GLX_VENDOR_LIBRARY_NAME=nvidia binary_path

like

__NV_PRIME_RENDER_OFFLOAD=1 __GLX_VENDOR_LIBRARY_NAME=nvidia ~/.steam/steam/steamapps/common/Kerbal\ Space\ Program/KSP.x86_64

for my beloved Kerbal Space Program.

The only reason to use switching to full NV mode was that VMware player wasn’t quite working well with this offsetting solution but that’s something I can totally live without. Thanks again!

Err… something maybe wrong on your end then?
https://aur.archlinux.org/packages/?K=optimus-manager


It seems you dont understand how PRIME works, or with steam particularly.
You just need prime-run.
And in the case of steam, set the game launch options (assuming no others):

prime-run %command%

Quite expected … its a hacky tool, that can be accomplished other ways, but most people dont need in any case. “Hybrid” mode is how PRIME works by default. Enabling or disabling one card or another doesnt require extra software.

Also worth noting, is that, if you followed optimus-manager instructions to augment sdd.conf, you may want to undo that. v1.3.1 README · Askannz/optimus-manager Wiki · GitHub

Thanks @cscs, I definitely don’t understand how PRIME works. Is prime-run doing anything else besides setting those two env vars? Any reading you’d recommend to understand it better?

Close, but with a dynamic variable for the input, and an extra flag for vulkan:

__NV_PRIME_RENDER_OFFLOAD=1 __VK_LAYER_NV_optimus=NVIDIA_only __GLX_VENDOR_LIBRARY_NAME=nvidia "$@"

(svntogit-packages/prime-run at packages/nvidia-prime · archlinux/svntogit-packages · GitHub)

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