Translation(s): English - Español - Français - Русский - 简体中文
该文档说明了如何在Debian系统中使用NVIDIA的显卡。
目录
开源驱动
Debian 有三种支持NVIDIA显卡的开源驱动,你可以查看到你正在使用哪一种:
$ grep -B2 'Module class: X.Org Video Driver' /var/log/Xorg.0.log
你可以简单地 配置X 来改变所使用的开源驱动。
没有一个开源驱动能够完全支持3D加速, 即使是 Nouveau 驱动拥有3D加速. 只有闭源的 nvidia 支持完全的3D加速。
vesa
vesa 驱动是一个通用的视频驱动程序。
nv
nv 驱动通常比vesa驱动得到更好的性能,但是它没有包含在wheezy或者更新的版本中。
Nouveau
除了vesa 和 nv, Debian从squeeze开始包含Nouveau驱动. Nouveau驱动从官方NVIDIA驱动经过逆向工程得到。这些驱动都是实验性的,这个驱动是不推荐的,除非你的nv驱动有问题并且你不想使用nvidia驱动。 Nouveau 驱动从Wheezy开始变得稳定.
驱动安装
为了使用 nouveau 驱动, 你的内核 drm 版本和你的 libdrm 版本需要匹配。基本上安装可以以这种方式来做:
# apt-get install xserver-xorg-video-nouveau
然后 配置X并且设置 nouveau 作为你的设备驱动。
英伟达专有驱动
步骤
选择驱动程序版本
Debian 7 "Wheezy"有三种可用的驱动程序版本:
For GeForce 6xxx and higher GPUs.
For GeForce 5xxx / GeForce FX GPUs.
For GeForce 2, GeForce 3 and GeForce 4 GPUs.
Debian 6.0 "Squeeze"有三种可用的驱动程序版本:
For GeForce 6xxx and higher GPUs, through to some GeForce 400 series.
For GeForce 5xxx / GeForce FX GPUs.
版本 96.43.18 (legacy GPUs) (支持的设备)
71.86.xx 驱动 - 支持 NVIDIA NV4/NV5/NV6/NV10/NV15 GPUs 和相关变化型号 - 不可用,由于其不支持Xorg X server1.4以后的版本 (620526, 708338).
For GeForce 2, GeForce 3 and GeForce 4 GPUs.
所有上面的驱动程序版本都只有 x86 和 x86-64 架构可用,分别对应 (Debian i386 和 AMD64).
安装
Debian 7 "Wheezy"
版本 304.88
为了支持英伟达(?GeForce)6xxx 和更高的GPUs (支持的设备). 对于更老的设备,参见 Version 173.14.35 (legacy GPUs) and 版本 96.43.23 (legacy GPUs).
增加 "contrib" 和 "non-free" 组件到 /etc/apt/sources.list, 例如:
# Debian 7 "Wheezy" deb http://http.debian.net/debian/ wheezy main contrib non-free
更新的可用的软件包列表.安装适当的 linux-headers 和 kernel module 软件包:
# aptitude update # aptitude -r install linux-headers-$(uname -r|sed 's,[^-]*-[^-]*-,,') nvidia-kernel-dkms
这也将安装推荐的 nvidia-glx 软件包. DKMS将为系统构建nvidia模块。
使用 手动方式 或者 nvidia-xconfig,这将创建一个基本的xorg.conf文件
重启系统以在启动时将nouveau(内核驱动)加入黑名单.
版本 173.14.35 (legacy GPUs)
为了支持英伟达(?GeForce)5xxx / FX GPUs (支持的设备).
增加 "contrib" 和 "non-free" 组件到 /etc/apt/sources.list, 例如:
# Debian 7 "Wheezy" deb http://http.debian.net/debian/ wheezy main contrib non-free
更新的可用的软件包列表。安装适当的 linux-headers 和 kernel module软件包:
# aptitude update # aptitude -r install linux-headers-$(uname -r|sed 's,[^-]*-[^-]*-,,') nvidia-kernel-legacy-173xx-dkms
这也将安装推荐的 nvidia-glx-legacy-173xx 软件包。DKMS将为系统构建nvidia模块。
使用 手动方式 或者 nvidia-xconfig,这将创建一个基本的xorg.conf文件
重启系统以在启动时将nouveau(内核驱动)加入黑名单.
版本 96.43.23 (legacy GPUs)
为了支持?GeForce 2, GeForce 3 和 GeForce 4 GPUs (支持的设备).
增加 "contrib" 和 "non-free" 组件到 /etc/apt/sources.list, 例如:
# Debian 7 "Wheezy" deb http://http.debian.net/debian/ wheezy main contrib non-free
更新的可用的软件包列表。安装适当的 linux-headers 和 kernel module软件包:
# aptitude update # aptitude -r install linux-headers-$(uname -r|sed 's,[^-]*-[^-]*-,,') nvidia-kernel-legacy-96xx-dkms
这也将安装推荐的 nvidia-glx-legacy-96xx 软件包。DKMS将为系统构建nvidia模块。
使用 手动方式 或者 nvidia-xconfig,这将创建一个基本的xorg.conf文件.
重启系统以在启动时将nouveau(内核驱动)加入黑名单.
Debian 6.0 "Squeeze"
版本 195.36.31
为了支持英伟达 6xxx 和更新的 GPUs (supported devices), 以及包括一些 GeForce 400 系列的设备. 对于更老的设备, 参见 版本 173.14.27 (legacy GPUs) 和 版本 96.43.18 (legacy GPUs).
增加 "contrib" 和 "non-free" 组件到 /etc/apt/sources.list, 例如:
# Debian 6.0 "Squeeze" deb http://http.debian.net/debian/ squeeze main contrib non-free
更新的可用的软件包列表。安装适当的 linux-headers 和 kernel module软件包:
# aptitude update # aptitude -r install linux-headers-2.6-$(uname -r|sed 's,[^-]*-[^-]*-,,') nvidia-kernel-dkms
这也将安装推荐的 nvidia-glx 软件包. DKMS将为系统构建nvidia模块。
更新 initial ramdisk 使其把 nouveau 包含在黑名单中.(613951):
# update-initramfs -u
重启系统以在启动时将nouveau(内核驱动)加入黑名单.
版本 173.14.27 (legacy GPUs)
为了支持 GeForce 5xxx / GeForce FX GPUs (supported devices).
增加 "contrib" 和 "non-free" 组件到 /etc/apt/sources.list, 例如:
# Debian 6.0 "Squeeze" deb http://http.debian.net/debian/ squeeze main contrib non-free
更新的可用的软件包列表。 Install the appropriate linux-headers and kernel module packages:
# aptitude update # aptitude -r install linux-headers-2.6-$(uname -r|sed 's,[^-]*-[^-]*-,,') nvidia-kernel-legacy-173xx-dkms
This will also install the recommended nvidia-glx-legacy-173xx package. DKMS will build the nvidia module for your system.
Update the initial ramdisk to include the nouveau blacklist (613951):
# update-initramfs -u
重启系统以在启动时将nouveau(内核驱动)加入黑名单.
版本 96.43.18 (legacy GPUs)
为了支持 GeForce 2, GeForce 3 and GeForce 4 GPUs (supported devices).
增加 "contrib" 和 "non-free" 组件到 /etc/apt/sources.list, 例如:
# Debian 6.0 "Squeeze" deb http://http.debian.net/debian/ squeeze main contrib non-free
更新的可用的软件包列表。 Install the appropriate linux-headers and kernel module packages:
# aptitude update # aptitude -r install linux-headers-2.6-$(uname -r|sed 's,[^-]*-[^-]*-,,') nvidia-kernel-legacy-96xx-dkms
This will also install the recommended nvidia-glx-legacy-96xx package. DKMS will build the nvidia module for your system.
Update the initial ramdisk to include the nouveau blacklist (613951):
# update-initramfs -u
重启系统以在启动时将nouveau(内核驱动)加入黑名单.
配置
由于 Xorg不会自动检测英伟达显卡驱动,因此必须提供一个配置文件。例如:
/etc/X11/xorg.conf.d/20-nvidia.conf
Section "Device" Identifier "My GPU" Driver "nvidia" EndSection
上面的配置文件可以通过以下命令来创建:
# mkdir /etc/X11/xorg.conf.d # echo -e 'Section "Device"\n\tIdentifier "My GPU"\n\tDriver "nvidia"\nEndSection' > /etc/X11/xorg.conf.d/20-nvidia.conf
请注意这个命令在使用了“英伟达-优驰”技术的系统中会破坏你的Xorg配置。对于这样的硬件, 参见 Bumblebee 。
这时候重启系统使 nouveau 驱动加入黑名单。
更多的配置信息 .
检查驱动是否工作
为了检查是否正在使用加速, 使用 glxinfo程序. 这个程序是在 mesa-utils 软件包中. 如果
$ glxinfo |grep rendering
返回值为 "direct rendering: Yes", 加速已经启用.
更多信息
For more information about the drivers, see:
These files have loads of information about options and for troubleshooting NVIDIA's proprietary drivers. Here's an enticement for you to read them: somewhere in one of them you can find an explanation of how to suppress the NVIDIA splash screen every time you start an X server (hint: search for "NoLogo").
/usr/share/doc/nvidia-glx/README.Debian
/usr/share/doc/nvidia-glx/README.txt.gz
You can adjust the clock rates of your GPU and video RAM by running nvclock, nvclock_gtk, or nvclock_qt, available respectively in the nvclock, nvclock-gtk, and nvclock-qt packages. Obligatory warning: you can destroy your video hardware with these tools if you're not careful.
You can adjust some other, relatively obscure settings of the driver by running nvidia-settings, available in the nvidia-settings package.
另请参阅
?/Troubleshooting
本文链接:https://www.kinber.cn/post/4802.html 转载需授权!
推荐本站淘宝优惠价购买喜欢的宝贝: