0%

Linux Nvidia 驱动更新

安装 nvidia 驱动,出现了一个错误:

1
2
3
4
5
6
ERROR: An NVIDIA kernel module 'nvidia' appears to already be loaded in your kernel.  This may be because it is in use (for
example, by an X server, a CUDA program, or the NVIDIA Persistence Daemon), but this may also happen if your kernel was
configured without support for module unloading. Please be sure to exit any programs that may be using the GPU(s) before
attempting to upgrade your driver. If no GPU-based programs are running, you know that your kernel supports module
unloading, and you still receive this message, then an error may have occured that has corrupted an NVIDIA kernel module's
usage count, for which the simplest remedy is to reboot your computer.

这是因为系统中已经有 nvidia 驱动在运行着了。所以在安装新的驱动之前,要先解决就旧的驱动。
1
2
3
echo 'blacklist nvidia' > /etc/modprobe.d/blacklist.conf
bash NVIDIA-Linux-x86_64-xxx.xx.run --uninstall # uninstall 这一步根据具体情况不同
reboot

重启后再安装一次,显示 driver is installed successfully。运行 nvidia-smi 检查 nvidia 驱动版本:
pic01

支持一根棒棒糖!