Ubuntu 升级cuda版本与切换

  • 下载cuda版本

进:CUDA Toolkit 12.2 Downloads | NVIDIA Developer

Ubuntu 升级cuda版本与切换_第1张图片

wget https://developer.download.nvidia.com/compute/cuda/12.2.0/local_installers/cuda_12.2.0_535.54.03_linux.run

sudo sh ./cuda_12.2.0_535.54.03_linux.run --toolkit --silent --override

修改环境变量:

vim ~/.bashrc

source ~/.bashrc

export PATH=/usr/local/cuda-12.2/bin:$PATH
export LD_LIBRARY_PATH=/usr/local/cuda-12.2/lib64:$LD_LIBRARY_PATH

nvcc -V

Ubuntu 升级cuda版本与切换_第2张图片

  • 切换版本:

参考:https://blog.csdn.net/weixin_38705903/article/details/101850116

你可能感兴趣的:(#,tools,ubuntu,linux)