I recently bought a new laptop (system info below), and I can’t get it to boot without setting nomodeset in the boot menu (by pressing e on the latest derivation and then adding nomodeset at the end of the line). I followed the instructoins at NVIDIA - Official NixOS Wiki but no matter how many variations of the configuration I’ve tried I just couldn’t get it to boot without that option.
Here is the the output of journalctl -b -1 --no-pager: pastebin. I had to hold the power button and force shut-down the laptop, hense the abrupt end of the file.
Here is my current configuration.nix file:
...
hardware.graphics.enable = true;
services.xserver.videoDrivers = [
"nvidia"
"modesetting"
];
hardware.nvidia = {
modesetting.enable = true;
powerManagement.enable = true;
open = false;
nvidiaSettings = true;
package = config.boot.kernelPackages.nvidiaPackages.stable;
};
hardware.nvidia.prime = {
sync.enable = true;
intelBusId = "PCI:0@0:2:0";
nvidiaBusId = "PCI:43@0:0:0";
};
...
System info:
OS: NixOS 25.11 (Xantusia) x86_64
Host: HP OmniBook 7 Laptop 17-dc0xxx
Kernel: Linux 6.12.76
DE: GNOME 49.2
WM: Mutter (Wayland)
CPU: Intel(R) Core(TM) Ultra 7 258V (8) @ 4.80 GHz
GPU 1: NVIDIA GeForce RTX 4050 Max-Q / Mobile [Discrete]
GPU 2: Intel Arc Graphics 130V / 140V [Integrated]
Memory: 5.33 GiB / 30.98 GiB (17%)
lscpi output:
$ lspci -D -d ::03xx
0000:00:02.0 VGA compatible controller: Intel Corporation Lunar Lake [Intel Arc Graphics 130V / 140V] (rev 04)
0000:2b:00.0 VGA compatible controller: NVIDIA Corporation AD107M [GeForce RTX 4050 Max-Q / Mobile] (rev a1)