Solved FreeBSD 15 Nvidia issue

Hi all,

I have done a new install of FreeBSD 15 and also the Nvidia driver for my GPU.

I followed the handbook and guide to get to this point, I have done the following so far:

1. Installed Xorg, i3, Nvidia-driver, nvidia-settings
2. added 'kld_list="nvidia-modeset nvidia" to /etc/rc.conf
3. ensure bus is running
4. created a machine id

when trying to launch i3 via startx I get the following error:

(EE) NVIDIA: Failed to initialise the Nvidia kernel module.

So I don't understand why the module is not being loaded.

Any help here would be greatly appreciated, driver version of Nvidia is the 580 version.

Thanks
 
You've not at all described about your hardware, so everything below are all by uncertain predictions.

First of all, you can confirm whether nvidia-modeset.ko and nvidia.ko are loaded or not with kldstat(8).

And you need to add your local user you're logged in is needed to be a member of video group (not all X11 WMs/DEs require it, but Wayland should, and some display manager could require it, too. But I've never tried i3).

Assuming the above are OK, are you sure your GPU is supported by 580 series of drivers?

And as you're not using any of graphics/nvidia-drm-*-kmod (default for 15.0-Release is graphics/nvidia-drm-66-kmod), you need manual configuration.

If you're running on notebooks with hybrid graphics (Optimus), graphics/nvidia-drm-66-kmod should be mandatory unless you can completely disable iGPU.

Some notebooks have external monitor port (HDMI or DP, depends on the hardware design) dedicated for nvidia dGPU.

This is because x11-servers/xorg-server hesitates to auto-configure proprietary nvidia driver and only looks for x11-drivers/xf86-video-nv and nonexisitent nouveau driver for nvidia GPUs.

Follow Example 3 in Chapter 5.5.2 of the Handbook.

Note that you need x11/nvidia-kmod, too, but it should be automatically pulled in as a dependency when you installed x11/nvidia-driver.
 
Hi thanks for the response.

Yes I have the above and I know my GPU is supported by the 580 driver.

In my terminal I have just done 'kldload nvidia-modeset'

Then I ran 'startx' and it's working.

What is confusing me now is that in /etc/rc.conf I have the following line:

kld_list="nvidia-modeset nvidia"

But it's obviously not being loaded on boot.

Thanks
 
Hi thanks for the response.

Yes I have the above and I know my GPU is supported by the 580 driver.

In my terminal I have just done 'kldload nvidia-modeset'

Then I ran 'startx' and it's working.

What is confusing me now is that in /etc/rc.conf I have the following line:

kld_list="nvidia-modeset nvidia"

But it's obviously not being loaded on boot.

Thanks
So, if the kld_list line you've written is NOT actually copy&pasted from your /etc/rc.conf, are you sure there's no typo?

And if you have another (or more) kld_list line in your /etc/rc.conf AND it's actually in the same form as the line for nvidia-modeset, it would simply override any prior kld_list lines.

If it's the case, all kld_list lines other than exactly the first one should be in the form like below (assuming you have one prior to nvidia-modeset one).
Code:
kld_list="${kld_list} nvidia-modeset nvidia"

And note that nvidia.ko should be pulled in as the dependency by nvidia-modeset.ko. So
Code:
kld_list="${kld_list} nvidia-modeset"
should be sufficient here.
 
So, if the kld_list line you've written is NOT actually copy&pasted from your /etc/rc.conf, are you sure there's no typo?

And if you have another (or more) kld_list line in your /etc/rc.conf AND it's actually in the same form as the line for nvidia-modeset, it would simply override any prior kld_list lines.

If it's the case, all kld_list lines other than exactly the first one should be in the form like below (assuming you have one prior to nvidia-modeset one).
Code:
kld_list="${kld_list} nvidia-modeset nvidia"

And note that nvidia.ko should be pulled in as the dependency by nvidia-modeset.ko. So
Code:
kld_list="${kld_list} nvidia-modeset"
should be sufficient here.
Thanks I wasn't aware this was the case with kld_list, did your solution and it's worked, thanks again.
 
Back
Top