I am on a brand new install of EndeavourOS, running with the systemd-boot bootloader
So the issue I was seeing was that gamescope was not spawning an X11 window
I installed nvidia drivers with: nvidia-inst --32 --conf
I saw that nvidia-inst was going to add nvidia-drm.modeset=1 to /etc/kernel/cmdline for me, this kernel parameter is a requirement for gamescope to function properly.
When I saw that gamescope was not working, on a hunch I just executed sudo reinstall-kernels I found this by looking up the new documentation (suspecting that perhaps kernel parameter was not loaded properly) and sure enough it worked
I feel like this should have been in the release notes. or… did I encounter a bug with nvidia-inst? Should nvidia-inst have executed reinstall-kernels for me?
We have package nvidia-hook that runs reinstall-kernels if package kernel-install-for-dracut is installed.
It runs when an nvidia driver, e.g. nvidia-dkms package is installed, updated, or removed.
I do not want to reinstall my system again, I do have a spare system I could try to replicate this on and see if I can reproduce it and report back later, but I’m not sure it is working. Am curious to hear if others have run into a similar issue.
I found the script you were referring to, I tested it out and it should have worked:
/etc/pacman.d $ cat /usr/share/libalpm/hooks/eos-nvidia-fix.hook
[Trigger]
Operation = Install
Operation = Upgrade
Operation = Remove
Type = Package
Target = nvidia-dkms
Target = nvidia
Target = nvidia-lts
[Action]
Depends = mkinitcpio
When = PostTransaction
Exec = /usr/bin/eos-nvidia-fix
/etc/pacman.d $ cat /usr/bin/eos-nvidia-fix
#!/bin/bash
Main() {
local installed="$(pacman -Qq kernel-install-for-dracut eos-dracut mkinitcpio 2>/dev/null)"
if [[ "$installed" =~ kernel-install-for-dracut ]] ; then
reinstall-kernels
elif [[ "$installed" =~ eos-dracut ]] ; then
dracut-rebuild
elif [[ "$installed" =~ mkinitcpio ]] ; then
mkinitcpio -P
else
local progname="$(basename "$0")"
echo "warning: $progname: cannot perform requested operation because required package(s) are missing."
fi
}
Main "$@"
Edit: After reading through this the only glaring issue in the hook file is: Depends = mkinitcpio
That’s the thing, mkinitcpio is not installed anymore by default with systemd-boot, so it might make sense why the hook never executed… right?
Nice catch! That sounds like the problem.
This was changed very recently, and looks like this went unnoticed.
If you simply remove that line, does it work better?
I’m running systemd-boot, dracut
I updated my system, and nvidia-dkms got updated but the kernel did not rebuild! so I got an api mismatch when rebooted and no nvidia!
journalctl relevant log
...
ene 22 20:41:22 think kernel: NVRM: API mismatch: the client has the version 525.85.05, but
NVRM: this kernel module has the version 525.78.01. Please
NVRM: make sure that this kernel module and all NVIDIA driver
NVRM: components have the same version.
...