执行安装出错
sh cuda_9.0.176_384.81_linux.run
Installing the NVIDIA display driver...
A system reboot is required to continue installation. Please reboot then run the installer again. An attmept has been made to disable Nouveau. If this message persists after reboot, please see the display driver log file at /var/log/nvidia-installer.log for more information.
查看日志信息
cat /var/log/nvidia-installer.log
ERROR: The Nouveau kernel driver is currently in use by your system. This driver is incompatible with the NVIDIA driver, and must be disabled before proceeding. Please consult the NVIDIA driver README and your Linux distribution's documentation for details on how to correctly disable the Nouveau kernel driver.
WARNING: One or more modprobe configuration files to disable Nouveau are already present at: /usr/lib/modprobe.d/nvidia-installer-disable-nouveau.conf, /etc/modprobe.d/nvidia-installer-disable-nouveau.conf. Please be sure you have rebooted your system since these files were written. If you have rebooted, then Nouveau may be enabled for other reasons, such as being included in the system initial ramdisk or in your X configuration file. Please consult the NVIDIA driver README and your Linux distribution's documentation for details on how to correctly disable the Nouveau kernel driver.
-> For some distributions, Nouveau can be disabled by adding a file in the modprobe configuration directory. Would you like nvidia-installer to attempt to create this modprobe file for you? (Answer: Yes)
禁用nouveau模块即可解决
首先查看模块
lsmod | grep nouveau
nouveau 1622010 0
video 24520 1 nouveau
mxm_wmi 13021 1 nouveau
i2c_algo_bit 13413 2 mgag200,nouveau
drm_kms_helper 159169 2 mgag200,nouveau
ttm 99345 2 mgag200,nouveau
drm 370825 5 ttm,drm_kms_helper,mgag200,nouveau
i2c_core 40756 7 drm,i2c_i801,ipmi_ssif,drm_kms_helper,mgag200,i2c_algo_bit,nouveau
wmi 19070 2 mxm_wmi,nouveau
修改配置把该模块加入黑名单
vi /etc/modprobe.d/blacklist.conf
blacklist nouveau
重建initramfs image文件
mv /boot/initramfs-$(uname -r).img /boot/initramfs-$(uname -r).img.bak
dracut -v /boot/initramfs-$(uname -r).img $(uname -r)
Executing: /usr/sbin/dracut -v /boot/initramfs-3.10.0-693.el7.x86_64.img 3.10.0-693.el7.x86_64
dracut module 'busybox' will not be installed, because command 'busybox' could not be found!
dracut module 'busybox' will not be installed, because command 'busybox' could not be found!
Including module: bash
Including module: nss-softokn
Including module: i18n
......
重启服务器
再次查看nouveau模块,发现已经消失,执行cuda安装程序也不会报错。