ubuntu 安装NVIDIA驱动或CUDA报错:“The driver installation is unable to locate the kernel source....” 或者是无法登录系统界(loop login )
主要原因更主板的BIOS设置有关!!
UEFI下的设置
UEFI禁用Fast Boot
方法一:
Disable UEFI Secure Boot (if possible), or use a kernel that doesn't require signed modules.How to disable Secure Boot on Ubuntu, then!?!?
sudo apt install mokutil
sudo mokutil --disable-validation
Since questions may arise, see third party kernel modules on UEFI with enabled Secure Boot and the consequences of disabling it.
方法二:
重启机器按F2 进入BIOS系统,找到Boot (启动)选项
(1)Security 中的 Secure Boot 如果是Windows UTFILE system ,务必设置为“Disabled" (一般设置这个就可以了)
卸载:
4.6. Uninstallation
To uninstall the CUDA Toolkit, run the uninstallation script provided in the bindirectory of the toolkit. By default, it is located in /usr/local/cuda-9.0/bin:
$ sudo /usr/local/cuda-9.0/bin/uninstall_cuda_9.0.pl
To uninstall the NVIDIA Driver, run nvidia-uninstall:
$ sudo /usr/bin/nvidia-uninstall
To enable the Nouveau drivers, remove the blacklist file created in the DisablingNouveau section, and regenerate the kernel initramfs/initrd again as described in thatsection.