Nvidia driver crashing GDM repeatedly..

Looking to move over from fedora and undertaking a trial install on my laptop with a GT650M installed. I notices the second I install the nvidia drivers, gdm crashes (oh no! something has gone wrong white screen) this appears to happen regardless if I add kld_load nvidia-modeset or not in rc.conf - still happens if there is no entry at all. Decided to try with 12.2 and still the same. Any ideas where I'm going wrong.

Drivers installed via pkg install nvidia-driver. Noticed some threads suggest installing x11/nvidia-driver from ports. Would this be a better alternative or is this method out of date?
 
if I add kld_load nvidia-modeset or not in rc.conf
How exactly are you doing this? You should just add this:
Code:
kld_list="nvidia-modeset"
Do NOT put commands in /etc/rc.conf. This file is sourced numerous times by various rc(8) scripts and those commands would get executed each time this file is sourced. rc.conf(5) should only contain variables and nothing else.

Would this be a better alternative or is this method out of date?
It's going to make zero difference in this case.
 
Thanks, appreciate the help SirDice.

Sorry typo it was kld_list added to the bottom

My rc.conf looks like this

code
Code:
clear_tmp_enable="YES"
sendmail_enable="NONE"
hostname="nova.local"
keymap="uk.kbd"
ifconfig_re0="DHCP"
ifconfig_re0_ipv6="inet6 accept_rtadv"
ntpd_enable="YES"
powerd_enable="YES"
# Set dumpdev to "AUTO" to enable crash dumps, "NO" to disable
dumpdev="AUTO"
zfs_enable="YES"
hald_enable="YES"
dbus_enable="YES"
gnome_enable="YES"
gdm_enable="YES"
kld_list="nvidia-modeset"

Code:
pciconf -lv 
  vendor     = 'NVIDIA Corporation'
    device     = 'GK107M [GeForce GT 650M]'
    class      = display
    subclass   = VGA
ath0@pci0:3:0:0:    class=0x028000 card=0x21001a3b chip=0x0037168c rev=0x01 hdr=0x00
The obstacle I seem to be hitting is when I install the drivers through pkg install nvidia-driver which I believe installs this one

nvidia-driver-460.67

gdm breaks. I've also tried nvidia-driver-390-390.141 not knowing which one to use but still have the same issue. I've had to install with UEFI which I couldn't avoid as my drive is freeze locked for some reason by secure boot. Really, not sure if this would have any consequence thou..
 
I doubt it has anything to do with the NVidia driver. For the time being remove these two:
Code:
gnome_enable="YES"
gdm_enable="YES"
Add a /usr/local/etc/X11/xorg.conf.d/driver-nvidia.conf (this will make sure the NVidia driver is picked):
Code:
Section "Device"
        Identifier "Card0"
        Driver     "nvidia"
EndSection
Login as a regular user, and run startx. Make sure this works. Check /var/log/Xorg.0.log for any issues.

Then create ~/.xinitrc:
Code:
exec gnome-session
Run startx again. Now the Gnome desktop should start. Note that the first time you start a Gnome session it might take a while for things to get set up. When all that works enable gdm_enable="YES" again and see if it works correctly.
 
Back
Top