Skip to main content
Topic: [solved] Impossible to start X with nvidia driver (Read 1414 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

[solved] Impossible to start X with nvidia driver

Hello,

I need some help getting my new installation running with my nvidia card. I have done this many times with other distros (void, arch) and also on other machines(including with artix) without issue. I just can't figure out what is going wrong here.

I did a minimal installation of artix to track this problem down. I used the base openrc artix image.

Here is my graphics card:
Code: [Select]
lspci | grep VGA
01:00.0 VGA compatible controller: NVIDIA Corporation GF114 [GeForce GTX 560] (rev a1)

Installed packages:
Code: [Select]
pacman -S xorg xorg-xinit nvidia-390xx nvidia-390xx-settings

I generated the xorg.conf file.
Code: [Select]
nvidia-xconfig

After rebooting, when I launch startx I get this output:
Code: [Select]
xinit: giving up
xinit: unable to connect to X server: Connection refused
xinit: server error

This is the Xorg log:
Code: [Select]
[   351.440] (WW) Failed to open protocol names file lib/xorg/protocol.txt
[   351.446]
X.Org X Server 1.20.3
X Protocol Version 11, Revision 0
[   351.462] Build Operating System: Linux Artix Linux
[   351.467] Current Operating System: Linux localhost 4.19.6-artix1-1-ARTIX #1 SMP PREEMPT Sun Dec 2 18:38:46 UTC 2018 x86_64
[   351.467] Kernel command line: BOOT_IMAGE=/boot/vmlinuz-linux root=UUID=67f7dbd4-0728-4655-9224-72904a7d6868 rw quiet
[   351.479] Build Date: 26 October 2018  06:23:01PM
[   351.485] 
[   351.491] Current version of pixman: 0.36.0
[   351.503] Before reporting problems, check http://wiki.x.org
to make sure that you have the latest version.
[   351.503] Markers: (--) probed, (**) from config file, (==) default setting,
(++) from command line, (!!) notice, (II) informational,
(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
[   351.529] (==) Log file: "/var/log/Xorg.0.log", Time: Sun Dec  9 10:45:03 2018
[   351.537] (==) Using config directory: "/etc/X11/xorg.conf.d"
[   351.544] (==) Using system config directory "/usr/share/X11/xorg.conf.d"
[   351.546] (==) No Layout section.  Using the first Screen section.
[   351.546] (==) No screen section available. Using defaults.
[   351.546] (**) |-->Screen "Default Screen Section" (0)
[   351.546] (**) |   |-->Monitor "<default monitor>"
[   351.546] (==) No device specified for screen "Default Screen Section".
Using the first device section listed.
[   351.546] (**) |   |-->Device "Nvidia Card"
[   351.546] (==) No monitor specified for screen "Default Screen Section".
Using a default monitor configuration.
[   351.546] (==) Automatically adding devices
[   351.546] (==) Automatically enabling devices
[   351.546] (==) Automatically adding GPU devices
[   351.546] (==) Automatically binding GPU devices
[   351.546] (==) Max clients allowed: 256, resource mask: 0x1fffff
[   351.546] (WW) 'fonts.dir' not found (or not valid) in "/usr/share/fonts/misc".
[   351.546] Entry deleted from font path.
[   351.546] (Run 'mkfontdir' on "/usr/share/fonts/misc").
[   351.546] (WW) The directory "/usr/share/fonts/TTF" does not exist.
[   351.546] Entry deleted from font path.
[   351.546] (WW) The directory "/usr/share/fonts/OTF" does not exist.
[   351.546] Entry deleted from font path.
[   351.546] (WW) The directory "/usr/share/fonts/Type1" does not exist.
[   351.546] Entry deleted from font path.
[   351.546] (==) FontPath set to:
/usr/share/fonts/100dpi,
/usr/share/fonts/75dpi
[   351.546] (==) ModulePath set to "/usr/lib/xorg/modules"
[   351.546] (II) The server relies on udev to provide the list of input devices.
If no devices become available, reconfigure udev or disable AutoAddDevices.
[   351.546] (II) Module ABI versions:
[   351.546] X.Org ANSI C Emulation: 0.4
[   351.546] X.Org Video Driver: 24.0
[   351.546] X.Org XInput driver : 24.1
[   351.546] X.Org Server Extension : 10.0
[   351.547] (++) using VT number 2

[   351.550] (EE) systemd-logind: failed to get session: Launch helper exited with unknown return code 127
[   351.554] (--) PCI:*([email protected]:0:0) 10de:1201:1462:2383 rev 161, Mem @ 0xfc000000/33554432, 0xd8000000/134217728, 0xd4000000/67108864, I/O @ 0x0000bc00/128, BIOS @ 0x????????/131072
[   351.555] (WW) Open ACPI failed (/var/run/acpid.socket) (No such file or directory)
[   351.555] (II) LoadModule: "glx"
[   351.555] (II) Loading /usr/lib/xorg/modules/extensions/libglx.so
[   351.557] (II) Module glx: vendor="X.Org Foundation"
[   351.557] compiled for 1.20.3, module version = 1.0.0
[   351.557] ABI class: X.Org Server Extension, version 10.0
[   351.557] (II) LoadModule: "nvidia"
[   351.557] (II) Loading /usr/lib/xorg/modules/drivers/nvidia_drv.so
[   351.557] (II) Module nvidia: vendor="NVIDIA Corporation"
[   351.557] compiled for 4.0.2, module version = 1.0.0
[   351.557] Module class: X.Org Video Driver
[   351.557] (II) NVIDIA dlloader X Driver  390.87  Tue Aug 21 15:44:49 PDT 2018
[   351.557] (II) NVIDIA Unified Driver for all Supported NVIDIA GPUs
[   351.558] (II) Loading sub module "fb"
[   351.558] (II) LoadModule: "fb"
[   351.558] (II) Loading /usr/lib/xorg/modules/libfb.so
[   351.558] (II) Module fb: vendor="X.Org Foundation"
[   351.558] compiled for 1.20.3, module version = 1.0.0
[   351.558] ABI class: X.Org ANSI C Emulation, version 0.4
[   351.558] (II) Loading sub module "wfb"
[   351.558] (II) LoadModule: "wfb"
[   351.558] (II) Loading /usr/lib/xorg/modules/libwfb.so
[   351.558] (II) Module wfb: vendor="X.Org Foundation"
[   351.558] compiled for 1.20.3, module version = 1.0.0
[   351.558] ABI class: X.Org ANSI C Emulation, version 0.4
[   351.558] (II) Loading sub module "ramdac"
[   351.558] (II) LoadModule: "ramdac"
[   351.558] (II) Module "ramdac" already built-in
[   351.561] (EE) NVIDIA: Failed to initialize the NVIDIA kernel module. Please see the
[   351.561] (EE) NVIDIA:     system's kernel log for additional error messages and
[   351.561] (EE) NVIDIA:     consult the NVIDIA README for details.
[   351.564] (EE) NVIDIA: Failed to initialize the NVIDIA kernel module. Please see the
[   351.564] (EE) NVIDIA:     system's kernel log for additional error messages and
[   351.564] (EE) NVIDIA:     consult the NVIDIA README for details.
[   351.564] (EE) No devices detected.
[   351.564] (EE)
Fatal server error:
[   351.564] (EE) no screens found(EE)
[   351.564] (EE)
Please consult the The X.Org Foundation support
at http://wiki.x.org
 for help.
[   351.564] (EE) Please also check the log file at "/var/log/Xorg.0.log" for additional information.
[   351.564] (EE)
[   351.599] (EE) Server terminated with error (1). Closing log file.

------------------------------------------

So Xorg fails to initialize the nvidia module. I checked if module is loaded or not
Code: [Select]
lsmod | grep nvidia
no output

I tried to load the module myself
Code: [Select]
modprobe nvidia
modeprobe: FATAL: Module nvidia not found in directory /lib/modules/4.19.6-artix1-1-ARTIX

Am I missing something obvious? Or should I start suspecting that the package is broken?
Why is the nvidia module missing?

I appreciate any help, thank you.

Re: Impossible to start X with nvidia driver

Reply #1
I just installed Artix with KDE from scratch and installed nvidia similar to what you have done. I used the very latest version (world/nvidia, no version given) and it just worked.

I recall there was some trouble a while ago when the nvidia 300 series was the latest so I went back to funtoo and just yesterday got back Artix.

Can it be that the trouble was related to the 300-serise?  Have you tried the lates (world/nvidia)? Even if there is a compatibility issue with your card it might be interesting if you can modprobe the latest version.

I found this under /lib:
Code: [Select]
[~]# ll /lib/modules/extramodules-ARTIX/
total 12M
-rw-r--r-- 1 root root  25K Dec  7 21:36 nvidia-drm.ko.gz
-rw-r--r-- 1 root root 487K Dec  7 21:36 nvidia-modeset.ko.gz
-rw-r--r-- 1 root root 405K Dec  7 21:36 nvidia-uvm.ko.gz
-rw-r--r-- 1 root root  11M Dec  7 21:36 nvidia.ko.gz
-rw-r--r-- 1 root root   22 Dec  7 21:10 version
[ ~]# ll /lib/modules/4.19.6-artix1-1-ARTIX/            
total 12M
lrwxrwxrwx 1 root root   21 Dec  7 21:10 extramodules -> ../extramodules-ARTIX/
drwxr-xr-x 1 root root   88 Dec  7 21:10 kernel/
-rw-r--r-- 1 root root 1.4M Dec  7 21:36 modules.alias
-rw-r--r-- 1 root root 1.4M Dec  7 21:36 modules.alias.bin
-rw-r--r-- 1 root root 5.2K Dec  7 21:10 modules.builtin
-rw-r--r-- 1 root root 6.9K Dec  7 21:36 modules.builtin.bin
-rw-r--r-- 1 root root 672K Dec  7 21:36 modules.dep
-rw-r--r-- 1 root root 901K Dec  7 21:36 modules.dep.bin
-rw-r--r-- 1 root root  433 Dec  7 21:36 modules.devname
-rw-r--r-- 1 root root 210K Dec  7 21:10 modules.order
-rw-r--r-- 1 root root  662 Dec  7 21:36 modules.softdep
-rw-r--r-- 1 root root 557K Dec  7 21:36 modules.symbols
-rw-r--r-- 1 root root 686K Dec  7 21:36 modules.symbols.bin
-rw-r--r-- 1 root root 5.6M Dec  7 21:10 vmlinuz

[ ~]# find /lib/modules/4.19.6-artix1-1-ARTIX/kernel/ -name "*nvidia*"
/lib/modules/4.19.6-artix1-1-ARTIX/kernel/drivers/net/ethernet/nvidia

I take full responsibility of my Linux systems - I just need some help from time to time.

Re: Impossible to start X with nvidia driver

Reply #2
I had indeed tested with the latest version. It was actually my first attempt, before I figure that my GPU was not supported.

I just switched to the latest version of the driver, rebooted and tried to modpobe the module:
Code: [Select]
modprobe nvidia
modprobe ERROR: could not insert 'nvidia': No such device

This is interesting. The module does exist, it's probably just ignoring my GPU as it is not supported.

My /lib directory looks exactly like yours after installing the latest nvidia driver (makes sense) but with the 390 version I have an extra folder containing the nvidia modules. The name of the folder is 'extramodules-ARCH'...

Here are the files owned by the package nvidia-390xx
Code: [Select]
pacman -Ql nvidia-390xx
nvidia-390xx /usr/
nvidia-390xx /usr/lib/
nvidia-390xx /usr/lib/modprobe.d/
nvidia-390xx /usr/lib/modprobe.d/nvidia-390xx.conf
nvidia-390xx /usr/lib/modules/
nvidia-390xx /usr/lib/modules/extramodules-ARCH/
nvidia-390xx /usr/lib/modules/extramodules-ARCH/nvidia-drm.ko.gz
nvidia-390xx /usr/lib/modules/extramodules-ARCH/nvidia-modeset.ko.gz
nvidia-390xx /usr/lib/modules/extramodules-ARCH/nvidia-uvm.ko.gz
nvidia-390xx /usr/lib/modules/extramodules-ARCH/nvidia.ko.gz
nvidia-390xx /usr/share/
nvidia-390xx /usr/share/licenses/
nvidia-390xx /usr/share/licenses/nvidia-390xx/
nvidia-390xx /usr/share/licenses/nvidia-390xx/LICENSE

The obvious fix would be to move the content of 'extramodules-ARCH' to 'extramodules-ARTIX' but modrpobe gives me the same error as before: Module nvidia not found

Re: Impossible to start X with nvidia driver

Reply #3
There is a hint of missmatch between cuda, nvidia och kernel mentioned here: https://stackoverflow.com/questions/32493904/could-not-insert-nvidia-352-no-such-device

Do you have the latest kernel and the system up to date? Did you boot on the latest kernel?

You might also check out https://devtalk.nvidia.com/default/topic/968301/modprobe-error-could-not-insert-nvidia-no-such-device/?offset=4

I take full responsibility of my Linux systems - I just need some help from time to time.

Re: Impossible to start X with nvidia driver

Reply #4
Btw, have you got any interesting information in dmesg?
I take full responsibility of my Linux systems - I just need some help from time to time.

Re: Impossible to start X with nvidia driver

Reply #5
Nope, nothing in dmesg related to nvidia.

I confirm I boot on the latest kernel:
Code: [Select]
uname -a
Linux localhost 4.19.6-artix1-1ARTIX #1 SMP PREEMPT Sun Dec 2 18:38:46 UTC 2018 x86_64 GNU/Linux
and my system is up to date.

Your questions inspired me to try something else. I got a working solution. I installed the lts package (nvidia-390xx-lts) which drag the lts kernel version (4.14) with it.
I booted on that kernel and X now starts without error.

This solution is acceptable for me so i might leave it as it is. Thank you very much for your time :)

Re: Impossible to start X with nvidia driver

Reply #6
Not an NVidia user, but...

I find the arch wiki occasionally helpful from time to time.
Arch Wiki - NVIDIA goes to great lengths to discuss successful setup. Have you gone through the steps shown here?

Re: Impossible to start X with nvidia driver

Reply #7
Hi scottfurry,

I did go through that page as well as the troubleshooting page on the arch wiki. I tested the different configuration methods there (auto with xconfig and minimal). I don't really want to go through the whole driver compilation because I'm not using a custom kernel, so itshouldn't be needed.

I'm just wondering now if anyone got the version 390 of the nvidia driver to work on with Artix. It just seems broken to me: why would the driver be installed in '.lib/modules/extramodules-ARCH/' ?
This folder is not symlinked anywhere, unlike the '/lib/modules/extramodules-ARTIX/' which is symlinked in  '/lib/modules/4.19.6-artix1-1-ARTIX/'.

Re: Impossible to start X with nvidia driver

Reply #8
For what it's worth (I know it's not the same card), but I have an:

Code: [Select]
lspci | grep VGA
01:00.0 VGA compatible controller: NVIDIA Corporation GM107GLM [Quadro M2000M] (rev a2)


And these are the Nvidia packages I use.  I always stick to the DKMS packages and generally have zero issues.  I had issues in the past but it was because I was using pamac which wasn't re-running DKMS after a kernel update but since I went back to using pacman I have had zero issues for close to a year now and I do all updates (once the pgp keys are fixed and everything syncs) always.

Code: [Select]
nvidia-dkms 415.22-3
nvidia-settings 415.22-1
nvidia-utils 415.22-1
nvidia-utils-openrc 20180221-1

And this is the kernel I'm running:

Code: [Select]
uname -a
Linux XXXXXXXXX 4.19.6-artix1-1-ARTIX #1 SMP PREEMPT Sun Dec 2 18:38:46 UTC 2018 x86_64 GNU/Linux

Also, I've never generated a config, ever, using nvidia-xconfig
OS: Artix x86_64
Host: Predator PH517-61 V1.07
CPU: AMD Ryzen 7 2700 (16) @ 3.2GHz [112.4°F]
GPU: AMD ATI Radeon RX Vega 56/64
Memory: 1129MiB / 64390MiB

Re: Impossible to start X with nvidia driver

Reply #9
You need to go to the nvidia site, and find which driver supports that card.  I can't tell if your card is GForce 100 or 500 series, and they use different drivers.  Also, as someone else suggested, once you know which series driver to use, select the DKMS version.  Others MIGHT work, but there have been some issues where the latest packaged driver doesn't quite match the latest released kernel.  The DKMS version avoids that issue by preparing the module specifically for the current installed kernel.

Your note that the nvidia module is under ....ARCH.... is one of those mismatches.  It might be the right module, but it doesn't match the kernel.  Using DKMS avoids that problem.

Re: Impossible to start X with nvidia driver

Reply #10
Thanks guys for your replies.

I followed your advice. I went ahead and installed the DKMS package (nvidia-390xx-dkms in my case).
The package 'linux-headers' was also needed.

Artix now runs  with the latest linux kernel and nvidia driver loaded :)
As psyOnic mentioned, no xorg.conf needed.

Gentermnl, My card is a GTX 560, as mentioned in my first post. You must have missed it.

Thanks again.

Re: [solved] Impossible to start X with nvidia driver

Reply #11
Glad you got it working.  The newer DKMS (410 or 415) might also work, but no guarantees.  I have nothing using any current nvidia drivers.

I did see the NVIDIA Corporation GF114 [GeForce GTX 560] in your first post, but just wasn't sure if that made it a 100 or 500 series.  nVidia's numbering has often left me scratching my head  :)

Re: [solved] Impossible to start X with nvidia driver

Reply #12
Nope, latest driver does not work with my card.

I tested it out of curiosity.

Without DKMS, Xorg warns me that the version of the driver can't be used with my card. It also explicitly tells me to use the 390 version.
With DKMS, no mention of nvidia driver in xorg.log and no nvidia module loaded.

I will stick with the working version, which is the one I should run anyway, according to the Arch wiki, the nvidia site and Xorg itself.