作者zxvc (众生都是未来佛)
看板Linux
标题[分享] CentOS 7装CUDA心得
时间Thu Dec 14 14:49:10 2017
先声明确切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
--
※ 发信站: 批踢踢实业坊(ptt.cc), 来自: 140.115.73.148
※ 文章网址: https://webptt.com/cn.aspx?n=bbs/Linux/M.1513234155.A.258.html
1F:推 ddtsatan: 推 12/14 20:39