# CentOS8.2.2004 install Nvidia CUDA ### Install Nvidia Driver ### https://blog.gtwang.org/linux/centos-linux-7-install-nvidia-driver-tutorial/#google_vignette ### Install CUDA ### https://docs.vmware.com/tw/VMware-vSphere-Bitfusion/2.5/Example-Guide/GUID-2B258C7B-9542-4FC3-83F2-DF3F92CCCC7F.html --- 1. Install Package 1.1 啟用 EPEL ``` yum install -y epel-release ``` 1.2 更新核心 ``` yum update -y kernel ``` 1.3 安裝核心開發套件 ``` yum install -y kernel-devel-$(uname -r) kernel-headers-$(uname -r) ``` 1.2 安裝開發相關工具 ``` yum groupinstall -y "Development Tools" ``` ``` yum install -y tar pciutils libglvnd-devel ``` 3.4 安裝 DKMS ``` yum install -y dkms ``` 2. 停用 nouveau 這個開放原始碼的顯示卡驅動程式 2.1 Create a file at /etc/modprobe.d/blacklist-nouveau.conf with the following contents: blacklist nouveau options nouveau modeset=0 ``` echo $'blacklist nouveau\noptions nouveau modeset=0' > /etc/modprobe.d/blacklist-nouveau.conf ``` 2.2 Regenerate the kernel initramfs: ``` sudo dracut --force ``` 2.3 reboot check ``` lshw -numeric -C display ``` 3. Istall Nvidia Dirver 3.1 Download Nvidia Dirver 從 [NVIDIA 網站](https://www.nvidia.com/Download/index.aspx) 下載最新的顯示卡驅動程式。 ~~wget https://us.download.nvidia.com/tesla/460.73.01/NVIDIA-Linux-x86_64-460.73.01.run~~ ``` wget https://download.nvidia.com/XFree86/Linux-x86_64/470.42.01/NVIDIA-Linux-x86_64-470.42.01.run wget https://download.nvidia.com/XFree86/Linux-x86_64/470.57.02/NVIDIA-Linux-x86_64-470.57.02.run wget https://download.nvidia.com/XFree86/Linux-x86_64/470.63.01/NVIDIA-Linux-x86_64-470.63.01.run ``` 3.2 安裝 NVIDIA 驅動程式之前,必須將 X Window 停止,切換成文字模式: ``` sudo systemctl isolate multi-user.target ``` 3.3 執行剛剛下載的 NVIDIA 驅動程式安裝檔案: ``` sudo bash NVIDIA-Linux-x86_64-*.run ``` 3. Install Nvidia CUDA 3.1 Download Nvidia Dirver 從 [NVIDIA CUDA 網站](https://developer.nvidia.com/cuda-downloads) 下載最新的 CUDA 驅動程式。 ``` wget https://developer.download.nvidia.com/compute/cuda/11.4.0/local_installers/cuda_11.4.0_470.42.01_linux.run wget https://developer.download.nvidia.com/compute/cuda/11.4.1/local_installers/cuda_11.4.1_470.57.02_linux.run ``` 3.2 安裝 CUDA 之前,必須將 X Window 停止,切換成文字模式: ``` sudo systemctl isolate multi-user.target ``` 3.3 執行剛剛下載的 CUDA 安裝檔案: ``` sudo bash cuda_11.4.*.run ``` 4. Install gpu-burn 4.1 Get [gpu-burn](https://github.com/wilicc/gpu-burn) ``` git clone https://github.com/wilicc/gpu-burn.git ``` 4.2 run gpu-burn ``` cd gpu-burn; make; ./gpu_burn 30 ``` 5. Install Edward Tool 5.1 git clone ``` git clone http://192.168.25.11:3000/ed/QT_Cycling_Multi.git ``` 5.2 mv to /ED ``` mkdir /ED ; cp -r QT_Cycling_Multi/ /ED/ ``` 5.3 Run 001.ENV-Check.sh ``` cd /ED/QT_Cycling_Multi/ ; ./001.ENV-Check.sh ``` --- uninstall NVIDEA Driver & CUDA Toolkit ``` =========== = Summary = =========== Driver: Installed Toolkit: Installed in /usr/local/cuda-11.4/ Samples: Installed in /root/, but missing recommended libraries Please make sure that - PATH includes /usr/local/cuda-11.4/bin - LD_LIBRARY_PATH includes /usr/local/cuda-11.4/lib64, or, add /usr/local/cuda-11.4/lib64 to /etc/ld.so.conf and run ldconfig as root To uninstall the CUDA Toolkit, run cuda-uninstaller in /usr/local/cuda-11.4/bin To uninstall the NVIDIA Driver, run nvidia-uninstall Logfile is /var/log/cuda-installer.log ```
×
Sign in
Email
Password
Forgot password
or
Sign in via Google
Sign in via Facebook
Sign in via X(Twitter)
Sign in via GitHub
Sign in via Dropbox
Sign in with Wallet
Wallet (
)
Connect another wallet
Continue with a different method
New to HackMD?
Sign up
By signing in, you agree to our
terms of service
.