CentOS 7裝CUDA心得 - Linux

By Ula
at 2017-12-14T14:49
at 2017-12-14T14:49
Table of Contents
先聲明確切CUDA安裝步驟我不是很確定,若這篇有寫錯、漏寫什麼請見諒。
我的環境是:
CPU: Intel Core i7-7700
VGA: 技嘉 GV-N1070IXOC-8GD (GTX 1070)
OS: CentOS 7.4.1708 x64
CUDA Toolkit 9.1
安裝步驟基本上就是從官方說明書看起:
NVIDIA CUDA Installation Guide for Linux:
http://docs.nvidia.com/cuda/cuda-installation-guide-linux/index.html
在下載CUDA Toolkit的步驟時我是選: rpm (network)
接著照著說明書"3.2. Redhat/CentOS"作起。
此流程會同時安裝nVIDIA顯卡驅動,
不要自行又從官網下載驅動來裝,版本與CUDA Toolkit不合反而不能用!
作完後若想用內建Intel顯卡專作X Server顯示、nVIDIA顯卡專作CUDA計算,
請照說明書這段作:
"If the system is using a non-NVIDIA GPU to render the display, remove the
files at /etc/X11/xorg.conf and /usr/lib64/nvidia/xorg/libglx.so, and remove
the nomodeset kernel parameter from the boot command-line. "
然後說明書沒提到的是此時應該要"重開機"!
我猜可能是要讓"disable Nouveau driver"生效,所以必須重開機。
說明書"7.2.2. Install Writable Samples"建議要試跑測試程式,
才能驗證CUDA Toolkit是否安裝成功。可以試matrixMul這個sample:
cd NVIDIA_CUDA-9.1_Samples/0_Simple/matrixMul
make
./matrixMul
後記:
其實說明書寫得還滿完整、也有懶人包的安裝方式。
只是要注意一些細節。
--
楞嚴咒(附注音):
http://1drv.ms/1c0YbNt
--
我的環境是:
CPU: Intel Core i7-7700
VGA: 技嘉 GV-N1070IXOC-8GD (GTX 1070)
OS: CentOS 7.4.1708 x64
CUDA Toolkit 9.1
安裝步驟基本上就是從官方說明書看起:
NVIDIA CUDA Installation Guide for Linux:
http://docs.nvidia.com/cuda/cuda-installation-guide-linux/index.html
在下載CUDA Toolkit的步驟時我是選: rpm (network)
接著照著說明書"3.2. Redhat/CentOS"作起。
此流程會同時安裝nVIDIA顯卡驅動,
不要自行又從官網下載驅動來裝,版本與CUDA Toolkit不合反而不能用!
作完後若想用內建Intel顯卡專作X Server顯示、nVIDIA顯卡專作CUDA計算,
請照說明書這段作:
"If the system is using a non-NVIDIA GPU to render the display, remove the
files at /etc/X11/xorg.conf and /usr/lib64/nvidia/xorg/libglx.so, and remove
the nomodeset kernel parameter from the boot command-line. "
然後說明書沒提到的是此時應該要"重開機"!
我猜可能是要讓"disable Nouveau driver"生效,所以必須重開機。
說明書"7.2.2. Install Writable Samples"建議要試跑測試程式,
才能驗證CUDA Toolkit是否安裝成功。可以試matrixMul這個sample:
cd NVIDIA_CUDA-9.1_Samples/0_Simple/matrixMul
make
./matrixMul
後記:
其實說明書寫得還滿完整、也有懶人包的安裝方式。
只是要注意一些細節。
--
楞嚴咒(附注音):
http://1drv.ms/1c0YbNt
--
Tags:
Linux
All Comments

By George
at 2017-12-16T13:29
at 2017-12-16T13:29
Related Posts
PXE無硬碟開機 如何預設用root登入

By Mary
at 2017-12-13T22:02
at 2017-12-13T22:02
手機上好用的ODF軟體

By Adele
at 2017-12-12T10:44
at 2017-12-12T10:44
用docker內部作為員工的工作環境

By Yuri
at 2017-12-11T14:40
at 2017-12-11T14:40
進行Gaussian09計算時突然中止。

By Elma
at 2017-12-11T11:03
at 2017-12-11T11:03
請問怎麼加入 amdgpu.dc=1 來啟用 AMD 的 HDMI 音效

By Isabella
at 2017-12-09T21:50
at 2017-12-09T21:50