Need help with Nvidia GPU

Hello. I installed NixOS using the minimal ISO image on a laptop with integrated Intel graphics and a dedicated Nvidia GPU, but I’m having trouble configuring the Nvidia GPU for use. The NixOS Wiki and Manual haven’t been helpful. The system doesn’t even detect the Nvidia GPU; the lspci command only shows the Intel GPU. This issue doesn’t occur when I install NixOS using the graphical ISO.

Please share what config you tried so far for your nvidia card, as well as the specific model.

1 Like

If you install with the graphical ISO. Once you have installed you could look at that configuration.nix and see what is different from the one you are creating when you use minimal. There are also some helpful notes in the Wiki.

1 Like

My configuration file

“It’s been a long time since I installed it with a graphical ISO. Even back then, when I tried to use a minimal ISO, I ran into the exact same problem.”

And the other part? What is your GPU model?

1 Like

GPU Model - GeForce 940mx

That card is just barely still in the window for modern driver support, but it isn’t supported by the open driver.

You’ll need something like:

{
  services.xserver.videoDrivers = [ "nvidia" ];
  hardware.nvidia.open = false;
  # Don't set modesetting manually
}

I’m unsure if the gsp support that’s enabled by default might cause issues, too.

For the time being, try to get it to run without sync first. I.e., don’t set any other nvidia settings beyond those two.

If it still doesn’t work, try to get us dmesg output. This sentence makes me suspect hardware issues:

1 Like

“Thanks, everyone. In the end, I just gave up on NixOS and installed Ubuntu.”