100字范文,内容丰富有趣,生活中的好帮手!
100字范文 > Ubuntu 16.04 - GeForce RTX 2080 Ti 安装 GPU 显卡驱动 (Display Driver)

Ubuntu 16.04 - GeForce RTX 2080 Ti 安装 GPU 显卡驱动 (Display Driver)

时间:2020-02-23 07:33:25

相关推荐

Ubuntu 16.04 - GeForce RTX 2080 Ti 安装 GPU 显卡驱动 (Display Driver)

Ubuntu 16.04 - GeForce RTX 2080 Ti 安装 GPU 显卡驱动 (Display Driver)

NVIDIA 引领人工智能计算 - NVIDIA

/

GEFORCE 驱动程序

/drivers

0. Pre-installation Actions

卸载安装过的驱动,执行命令:

sudo /usr/bin/nvidia-uninstall

sudo apt-get remove --purge nvidia*

0.1 sudo service lightdm stop

strong@foreverstrong:~$ sudo service lightdm stop[sudo] password for strong:strong@foreverstrong:~$

0.2 sudo /usr/bin/nvidia-uninstall

strong@foreverstrong:~$ sudo /usr/bin/nvidia-uninstallstrong@foreverstrong:~$

If you plan to no longer use the NVIDIA driver, you should make sure that no X screens are configured to use the NVIDIA X driver in your X configuration file. If you used nvidia-xconfig to configure X, it may have created a backup of your original configuration. Would you like to runnvidia-xconfig --restore-original-backupto attempt restoration of the original X configuration file? -> No

Uninstallation of existing driver: NVIDIA Accelerated Graphics Driver for Linux-x86_64 (430.14) is complete. -> OK

查看电脑支持的驱动版本:

sudo apt-cache search nvidia*

查看 Ubuntu 推荐的驱动版本:

ubuntu-drivers devices

strong@foreverstrong:~$ ubuntu-drivers devices== /sys/devices/pci0000:00/0000:00:01.0/0000:01:00.0 ==vendor : NVIDIA Corporationmodalias : pci:v000010DEd00001B80sv00007377sd00001110bc03sc00i00driver : nvidia-384 - distro non-freedriver : nvidia-415 - third-party freedriver : nvidia-410 - third-party freedriver : nvidia-430 - third-party free recommendeddriver : nvidia-396 - third-party freedriver : xserver-xorg-video-nouveau - distro free builtindriver : nvidia-390 - third-party freedriver : nvidia-418 - third-party freestrong@foreverstrong:~$

BIOS 中务必关闭 Secure Boot。不然会出现 Unable to load the ‘nvidia-drm’ kernel module. 的报错。

1. 手动搜索驱动程序

2. 搜索结果

3. Linux x64 (AMD64/EM64T) Display Driver

NVIDIA-Linux-x86_64-430.14.run

4. Verify You Have a Supported Version of Linux

To determine which distribution and release number you’re running, type the following at the command line:

$ uname -m && cat /etc/*release

deepnorth@deepnorth-amax:~$ uname -m && cat /etc/*releasex86_64DISTRIB_ID=UbuntuDISTRIB_RELEASE=16.04DISTRIB_CODENAME=xenialDISTRIB_DESCRIPTION="Ubuntu 16.04.6 LTS"NAME="Ubuntu"VERSION="16.04.6 LTS (Xenial Xerus)"ID=ubuntuID_LIKE=debianPRETTY_NAME="Ubuntu 16.04.6 LTS"VERSION_ID="16.04"HOME_URL="/"SUPPORT_URL="/"BUG_REPORT_URL="/ubuntu/"VERSION_CODENAME=xenialUBUNTU_CODENAME=xenialdeepnorth@deepnorth-amax:~$

5. Verify the System Has gcc Installed

To verify the version of gcc installed on your system, type the following on the command line:

$ gcc --version

deepnorth@deepnorth-amax:~$ gcc --versiongcc (Ubuntu 5.4.0-6ubuntu1~16.04.11) 5.4.0 0609Copyright (C) Free Software Foundation, Inc.This is free software; see the source for copying conditions. There is NOwarranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.deepnorth@deepnorth-amax:~$

6. Verify the System has the Correct Kernel Headers and Development Packages Installed

The version of the kernel your system is running can be found by running the following command:

$ uname -r

deepnorth@deepnorth-amax:~$ uname -r4.15.0-54-genericdeepnorth@deepnorth-amax:~$

Ubuntu:

The kernel headers and development packages for the currently running kernel can be installed with:

$ sudo apt-get install linux-headers-$(uname -r)

deepnorth@deepnorth-amax:~$ uname -r4.15.0-54-genericdeepnorth@deepnorth-amax:~$deepnorth@deepnorth-amax:~$ sudo apt-get install linux-headers-$(uname -r)[sudo] password for deepnorth:Reading package lists... DoneBuilding dependency treeReading state information... Donelinux-headers-4.15.0-54-generic is already the newest version (4.15.0-54.58~16.04.1).linux-headers-4.15.0-54-generic set to manually installed.0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded.deepnorth@deepnorth-amax:~$

7. CTRL + ALT + F1 进入终端界面,关闭图形界面

deepnorth@deepnorth-amax:~$ sudo service lightdm stopdeepnorth@deepnorth-amax:~$

图形界面将会被关闭。可以使用 CTRL + ALT + F7 检查一下。

如果后续需要关闭图形界面,执行如下命令:

sudo /etc/init.d/lightdm stop

sudo service lightdm stop

如果后续需要开启图形界面,执行如下命令:

sudo service lightdm start

sudo /etc/init.d/lightdm start

8. Disabling Nouveau

To install the Display Driver, the Nouveau drivers must first be disabled. Each distribution of Linux has a different method for disabling Nouveau.

The Nouveau drivers are loaded if the following command prints anything:

$ lsmod | grep nouveau

deepnorth@deepnorth-amax:~$ lsmod | grep nouveaunouveau 1724416 0mxm_wmi16384 1 nouveauvideo 45056 1 nouveauttm 106496 2 ast,nouveaudrm_kms_helper 172032 2 ast,nouveaui2c_algo_bit 16384 3 igb,ast,nouveaudrm 401408 5 drm_kms_helper,ast,ttm,nouveauwmi24576 2 mxm_wmi,nouveaudeepnorth@deepnorth-amax:~$

Ubuntu:

Create a file at/etc/modprobe.d/blacklist-nouveau.confwith the following contents:

blacklist nouveau

options nouveau modeset=0

Regenerate the kernel initramfs:

$ sudo update-initramfs -u

i -> INSERTblacklist nouveauoptions nouveau modeset=0ESC -> 退出编辑模式:wq -> 保存

deepnorth@deepnorth-amax:~$ sudo vim /etc/modprobe.d/blacklist-nouveau.confdeepnorth@deepnorth-amax:~$ cat /etc/modprobe.d/blacklist-nouveau.confblacklist nouveauoptions nouveau modeset=0deepnorth@deepnorth-amax:~$ sudo update-initramfs -uupdate-initramfs: Generating /boot/initrd.img-4.15.0-54-genericW: Possible missing firmware /lib/firmware/ast_dp501_fw.bin for module astdeepnorth@deepnorth-amax:~$

9. 重启电脑,验证驱动是否禁用成功

deepnorth@deepnorth-amax:~$ rebootFailed to set wall message, ignoring: Interactive authentication required.Failed to reboot system via logind: Interactive authentication required.Failed to start reboot.target: Interactive authentication required.See system logs and 'systemctl status reboot.target' for details.Failed to open /dev/initctl: Permission deniedFailed to talk to init daemon.deepnorth@deepnorth-amax:~$deepnorth@deepnorth-amax:~$ sudo reboot

lsmod | grep nouveau如果没有输出内容,则禁用成功。

deepnorth@deepnorth-amax:~$ lsmod | grep nouveaudeepnorth@deepnorth-amax:~$

10. CTRL + ALT + F1 进入终端界面,关闭图形界面

deepnorth@deepnorth-amax:~$ sudo service lightdm stopdeepnorth@deepnorth-amax:~$

图形界面将会被关闭。可以使用 CTRL + ALT + F7 检查一下。

11. sudo sh ./NVIDIA-Linux-x86_64-430.14.run -no-opengl-files

deepnorth@deepnorth-amax:~$ cd software/deepnorth@deepnorth-amax:~/software$ lltotal 120776drwxrwxr-x 2 deepnorth deepnorth4096 7月 9 21:06 ./drwxr-xr-x 19 deepnorth deepnorth4096 7月 9 21:54 ../-rw-rw-r-- 1 deepnorth deepnorth 110886277 7月 9 21:04 NVIDIA-Linux-x86_64-430.14.run-rwxrwxrwx 1 deepnorth deepnorth 12771800 7月 9 09:20 teamviewer_13.2.75536_amd64.deb*deepnorth@deepnorth-amax:~/software$deepnorth@deepnorth-amax:~/software$ chmod a+x NVIDIA-Linux-x86_64-430.14.rundeepnorth@deepnorth-amax:~/software$deepnorth@deepnorth-amax:~/software$ lltotal 120776drwxrwxr-x 2 deepnorth deepnorth4096 7月 9 21:06 ./drwxr-xr-x 19 deepnorth deepnorth4096 7月 9 21:54 ../-rwxrwxr-x 1 deepnorth deepnorth 110886277 7月 9 21:04 NVIDIA-Linux-x86_64-430.14.run*-rwxrwxrwx 1 deepnorth deepnorth 12771800 7月 9 09:20 teamviewer_13.2.75536_amd64.deb*deepnorth@deepnorth-amax:~/software$

deepnorth@deepnorth-amax:~/software$ sudo sh ./NVIDIA-Linux-x86_64-430.14.run -no-opengl-files

-no-opengl-files 只安装驱动文件,不安装OpenGL文件。务必添加这个参数。

-no-x-check 安装驱动时不检查 x 服务,安装驱动时关闭 x 服务。

-no-nouveau-check 安装驱动时不检查 nouveau,安装驱动时禁用 nouveau。

The distribution-provided pre-install script failed! Are you sure you want to continue? -> Continue installation

Would you like to register the kernel module souces with DKMS? This will allow DKMS to automatically build a new module, if you install a different kernel later? -> Yes

Dynamic Kernel Module Support,DKMS:动态内核模块支持

WARNING: Unable to find a suitable destination to install 32-bit compatibility libraries. Your system may not be set up for 32-bit compatibility. 32-bit compatibility files will not be installed; if you wish to install them, re-run the installation and set a valid directory with the --compat32-libdir option. -> OK

Would you like to run the nvidia-xconfig utility to automatically update your X configuration file so that the NVIDIA X driver will be used when you restart X? Any pre-existing X configuration file will be backed up. -> Yes

Your X configuration file has been successfully updated. Installation of the NVIDIA Accelerated Graphics Driver for Linux-x86_64 (version: 430.14) is now complete. -> OK

deepnorth@deepnorth-amax:~/software$ sudo sh ./NVIDIA-Linux-x86_64-430.14.run -no-opengl-filesVerifying archive integrity... OKUncompressing NVIDIA Accelerated Graphics Driver for Linux-x86_64 430.14..........................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................deepnorth@deepnorth-amax:~/software$ (version: 430.14) is now complete.

12. nvidia-smi

deepnorth@deepnorth-amax:~/software$ nvidia-smiTue Jul 9 22:24:29 +-----------------------------------------------------------------------------+| NVIDIA-SMI 430.14 Driver Version: 430.14 CUDA Version: 10.2||-------------------------------+----------------------+----------------------+| GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC || Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. ||===============================+======================+======================|| 0 GeForce RTX 208... Off | 00000000:1B:00.0 Off | N/A || 32% 48C P0 66W / 250W |0MiB / 11019MiB |0%Default |+-------------------------------+----------------------+----------------------+| 1 GeForce RTX 208... Off | 00000000:1C:00.0 Off | N/A || 34% 49C P0 60W / 250W |0MiB / 11019MiB |0%Default |+-------------------------------+----------------------+----------------------+| 2 GeForce RTX 208... Off | 00000000:1D:00.0 Off | N/A || 34% 49C P0 63W / 250W |0MiB / 11019MiB |0%Default |+-------------------------------+----------------------+----------------------+| 3 GeForce RTX 208... Off | 00000000:1E:00.0 Off | N/A || 33% 49C P0 54W / 250W |0MiB / 11019MiB |0%Default |+-------------------------------+----------------------+----------------------+| 4 GeForce RTX 208... Off | 00000000:89:00.0 Off | N/A || 32% 48C P0 78W / 250W |0MiB / 11019MiB |0%Default |+-------------------------------+----------------------+----------------------+| 5 GeForce RTX 208... Off | 00000000:8A:00.0 Off | N/A || 34% 49C P0 65W / 250W |0MiB / 11019MiB |0%Default |+-------------------------------+----------------------+----------------------+| 6 GeForce RTX 208... Off | 00000000:8B:00.0 Off | N/A || 33% 49C P0 52W / 250W |0MiB / 11019MiB |1%Default |+-------------------------------+----------------------+----------------------+| 7 GeForce RTX 208... Off | 00000000:8C:00.0 Off | N/A || 33% 50C P0 55W / 250W |0MiB / 11019MiB |0%Default |+-------------------------------+----------------------+----------------------++-----------------------------------------------------------------------------+| Processes:GPU Memory || GPU PID Type Process name Usage||=============================================================================|| No running processes found |+-----------------------------------------------------------------------------+deepnorth@deepnorth-amax:~/software$

13. reboot

查看显卡驱动版本:

cat /proc/driver/nvidia/version

yongqiang@famu-sys:~$ cat /proc/driver/nvidia/versionNVRM version: NVIDIA UNIX x86_64 Kernel Module 390.48 Thu Mar 22 00:42:57 PDT GCC version: gcc version 5.4.0 0609 (Ubuntu 5.4.0-6ubuntu1~16.04.9) yongqiang@famu-sys:~$

deepnorth@deepnorth-amax:~/software$ cat /proc/driver/nvidia/versionNVRM version: NVIDIA UNIX x86_64 Kernel Module 430.14 Wed May 8 01:10:53 UTC GCC version: gcc version 5.4.0 0609 (Ubuntu 5.4.0-6ubuntu1~16.04.11)deepnorth@deepnorth-amax:~/software$

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。