如何让 GTX 1070 在 Arch Linux 上运行?

如何让 GTX 1070 在 Arch Linux 上运行?

我尝试从官方网站安装驱动程序“NVIDIA-Linux-x86_64-367.27”,但出现以下错误:

PATH: /usr/local/sbin:/usr/local/bin:/usr/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl

nvidia-installer command line:
    ./nvidia-installer

Unable to load: nvidia-installer ncurses v6 user interface

Unable to load: nvidia-installer ncurses user interface

Using built-in stream user interface
-> Detected 8 CPUs online; setting concurrency level to 8.
WARNING: You do not appear to have an NVIDIA GPU supported by the 375.20 NVIDIA Linux graphics driver installed in this system.  For further details, please see the appendix SUPPORTED NVIDIA GRAPHICS CHIPS in the README available on the Linux driver download page at www.nvidia.com.
-> License accepted.
-> Installing NVIDIA driver version 375.20.
-> Performing CC sanity check with CC="/usr/bin/cc".
ERROR: The kernel header file '/lib/modules/4.8.4-1-ARCH/build/include/linux/kernel.h' does not exist.  The most likely reason for this is that the kernel source path '/lib/modules/4.8.4-1-ARCH/build' is incorrect.  Please make sure you have installed the kernel source files for your kernel and that they are properly configured; on Red Hat Linux systems, for example, be sure you have the 'kernel-source' or 'kernel-devel' RPM installed.  If you know the correct kernel source files are installed, you may specify the kernel source path with the '--kernel-source-path' command line option.
ERROR: Installation has failed.  Please see the file '/var/log/nvidia-installer.log' for details.  You may find suggestions on fixing installation problems in the README available on the Linux driver download page at www.nvidia.com.

我不明白为什么我会收到此警告。

“警告:此系统中安装的 367.27 NVIDIA Linux 图形驱动程序似乎不支持您的 NVIDIA GPU。”

该 GPU 是直接从 MSI 购买的。

答案1

我强烈建议阅读NVIDIA 上的 Arch wiki而不是直接从 Nvidia 网站下载驱动程序。这是 wiki 中的相关部分:

对于 GeForce 400 系列卡和更新版本 [NVCx 及更新版本],请安装 nvidia 或 nvidia-lts 软件包以及 nvidia-libgl。如果这些软件包不起作用,nvidia-betaAUR 可能有提供支持的较新驱动程序版本。

所以看起来你应该安装英伟达包裹

pacman -S nvidia

然后它会询问您是否应该使用其他软件包。根据维基 - 你的卡需要Nvidia-libgl包裹。

答案2

您遇到的直接问题是缺少kernel.h文件,这会阻止为您的系统重建驱动程序。您应该安装内核头文件(linux-headers包)并尝试再次运行安装。

一旦安装成功,您收到的有关不受支持的硬件的警告可能会消失。如果没有,您将必须调查如何检测您的硬件以及为什么这些驱动程序无法与其一起工作。此时,提供硬件诊断工具(例如lspci和)的输出将很有用lshw

相关内容