歡迎來到Linux教程網
Linux教程網
Linux教程網
Linux教程網
您现在的位置: Linux教程網 >> UnixLinux >  >> Linux綜合 >> 學習Linux

Fedora 24 如何安裝 Nvidia 顯卡驅動

Fedora 24 如何安裝 Nvidia 顯卡驅動


Fedora 24 如何安裝 Nvidia 顯卡驅動


關於 Nvidia 驅動,我們就不再過多贅述了,本文教大家如何在 Fedora 24 上安裝 Nvidia 顯卡驅動。

首先我們需要安裝 kernel-devel 和 kernel-headers,如下命令:

[root@localhost ~]# dnf install kernel-devel kernel-headers
Last metadata expiration check: 0:53:22 ago on Tue Jun 28 09:45:14 2016.
Dependencies resolved.
=========================================================================
Package              Arch       Version            Repository     Size
=========================================================================
Installing:
kernel-devel         x86_64     4.5.7-300.fc24     updates         10 M
kernel-headers       x86_64     4.5.7-300.fc24     updates        1.0 M
Transaction Summary
=========================================================================
Install  2 Packages
Total download size: 11 M
Installed size: 42 M
Is this ok [y/N]: y
Downloading Packages:
(1/2): kernel-headers-4.5.7-300.fc24.x86_64.rpm  84 kB/s | 1.0 MB   00:12
(2/2): kernel-devel-4.5.7-300.fc24.x86_64.rpm   191 kB/s |  10 MB   00:55
-------------------------------------------------------------------------
Total                                           202 kB/s |  11 MB   00:57
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
Installing  : kernel-headers-4.5.7-300.fc24.x86_64                 1/2
Installing  : kernel-devel-4.5.7-300.fc24.x86_64                   2/2
Verifying   : kernel-devel-4.5.7-300.fc24.x86_64                   1/2
Verifying   : kernel-headers-4.5.7-300.fc24.x86_64                 2/2
Installed:
kernel-devel.x86_64 4.5.7-300.fc24    kernel-headers.x86_64 4.5.7-300.fc24
Complete!

安裝 gcc, dkms 和 acpid,命令如下:

[root@localhost ~]#dnf install gcc dkms acpid

到 官方網站下載驅動文件包,  NVIDIA-Linux-x86_64-367.27.run:

[root@localhost ~]# wget http://in.download.nvidia.com/XFree86/Linux-x86_64/367.27/NVIDIA-Linux-x86_64-367.27.run
--2016-06-28 10:19:16--  http://in.download.nvidia.com/XFree86/Linux-x86_64/367.27/NVIDIA-Linux-x86_64-367.27.run
Resolving in.download.nvidia.com (in.download.nvidia.com)... 117.239.240.42, 117.239.240.32
Connecting to in.download.nvidia.com (in.download.nvidia.com)|117.239.240.42|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 76945324 (73M) [application/octet-stream]
Saving to: ‘NVIDIA-Linux-x86_64-367.27.run’
NVIDIA-Linux-x86_64 100%[===================>]  73.38M  1.16MB/s    in 91s
2016-06-28 10:20:49 (825 KB/s) - ‘NVIDIA-Linux-x86_64-367.27.run’ saved [76945324/76945324]

修改 NVIDIA-Linux-x86_64-367.27.run 權限並安裝:

[root@localhost ~]#chmod +x NVIDIA-Linux-x86_64-367.27.run 

關閉 X-server 顯卡驅動並修改驅動鏈接:

[root@localhost ~]#rm /etc/systemd/system/default.target
rm: remove symbolic link '/etc/systemd/system/default.target'? y
[root@localhost ~]#ln -sf /lib/systemd/system/multi-user.target /etc/systemd/system/default.target

在上面的命令中,我們使用第一個命令來刪除默認的運行級別,並在下一個命令中,我們改變了運行級別為多用戶(這是等於運行3級(多用戶與文本模式))。

Blacklist nouveau at Boot Time and Post Boot

我們將創建一個文件disable-noveau.conf在/etc/modprobe.d/目錄如下:

[root@localhost ~]#echo 'blacklist nouveau' >> /etc/modprobe.d/disable-nouveau.conf
[root@localhost ~]#echo 'nouveau modeset=0' >> /etc/modprobe.d/disable-nouveau.conf

編輯 /boot/grub2/grub.cfg 文件:

linux16 /vmlinuz-4.5.7-300.fc24.x86_64+debug root=/dev/mapper/fedora-root ro rd.lvm.lv=fedora/root rd.lvm.lv=fedora/swap rhgb quiet LANG=en_US.UTF-

在rdblacklist=nouveau 按照下面內容添加:

linux16 /vmlinuz-4.5.7-300.fc24.x86_64+debug root=/dev/mapper/fedora-root ro rd.lvm.lv=fedora/root rd.lvm.lv=fedora/swap rdblacklist=nouveau rhgb quiet LANG=en_US.UTF-8

重啟系統:

[root@localhost ~]#reboot

使用 root 賬戶登錄系統:

fedora-24-run-level-3

如下圖,安裝驅動:

Fedora23-2016-06-28-11-16-10

選擇 Accept:

nvidia2

選擇“yes”:
Fedora23-2016-06-28-11-16-41

選擇“yes”:
Fedora23-2016-06-28-11-16-50

Fedora23-2016-06-28-11-17-24

Fedora23-2016-06-28-11-16-59

成功安裝後,修改默認:

[root@localhost ~]#rm /etc/systemd/system/default.target
[root@localhost ~]#ln -sf /lib/systemd/system/graphical.target /etc/systemd/system/default.target

設置:

nvidia-367

為Ubuntu 16.04安裝Nvidia驅動解決筆記本發熱風扇狂轉等問題 

Ubuntu 14.04 安裝 Nvidia 私有驅動並進行雙顯卡切換 

Ubuntu 12.04 系統下安裝Nvida 官方顯卡驅動教程 

Ubuntu 用戶安裝顯卡驅動 Nvidia Driver 334.21

如何在Ubuntu 13.10中安裝最新版的NVIDIA 331.20驅動

Linux 怎樣安裝 Nvidia 337.12 Beta 顯卡驅動

Ubuntu用戶怎樣安裝Nvidia最新顯卡驅動

http://xxxxxx/Linuxjc/1141023.html TechArticle

Copyright © Linux教程網 All Rights Reserved