驱动程序:安装失败 工具包:跳过安装

驱动程序:安装失败 工具包:跳过安装

我无法在 Ubuntu 14.04 上安装 CUDA 8 Toolkit。我收到此错误:

-

$ sudo ./cuda_8.0.44_linux.run 
    ------------------------------------------------------------
    Do you accept the previously read EULA?
    accept/decline/quit: 
    Do you accept the previously read EULA?
    accept/decline/quit: accept

    Install NVIDIA Accelerated Graphics Driver for Linux-x86_64 367.48?
    (y)es/(n)o/(q)uit: yes

    Do you want to install the OpenGL libraries?
    (y)es/(n)o/(q)uit [ default is yes ]: yes

    Do you want to run nvidia-xconfig?
    This will update the system X configuration file so that the NVIDIA X driver
    is used. The pre-existing X configuration file will be backed up.
    This option should not be used on systems that require a custom
    X configuration, such as systems with multiple GPU vendors.
    (y)es/(n)o/(q)uit [ default is no ]: y  

    Install the CUDA 8.0 Toolkit?
    (y)es/(n)o/(q)uit: y

    Enter Toolkit Location
     [ default is /usr/local/cuda-8.0 ]: 

    Do you want to install a symbolic link at /usr/local/cuda?
    (y)es/(n)o/(q)uit: y

    Install the CUDA 8.0 Samples?
    (y)es/(n)o/(q)uit: y

    Enter CUDA Samples Location
     [ default is /home/mona ]: 

    Installing the NVIDIA display driver...
    It appears that an X server is running. Please exit X before installation. If you're sure that X is not running, but are getting this error, please delete any X lock files in /tmp.

    ===========
    = Summary =
    ===========

    Driver:   Installation Failed
    Toolkit:  Installation skipped
    Samples:  Installation skipped


    Logfile is /tmp/cuda_install_1976.log

这些是日志文件:http://pastebin.com/KLAZ4b5ghttp://pastebin.com/wRJq8t51 在安装 CUDA 8 Toolkit 之前,我还安装了适用于 Tesla K40c GPU 的 Nvidia 驱动程序。

NVIDIA-Linux-x86_64-361.93.02.run

有什么指导可以指导如何修复吗?

答案1

首先要注意警告:

This option should not be used on systems that require a custom
X configuration, such as systems with multiple GPU vendors.

我的笔记本电脑上有 Intel HD4000 GPU 和 Nvidia GT650M,所以这对我来说可能是一个警告。一定要确定你安装的是什么!

至于错误消息,您必须在 X-Server 未运行时通过控制台运行安装。重新启动您的机器。在正常的 Ubuntu gooey(GUI)登录提示下按Ctrl+ Alt+ F1,控制台(基于文本)登录将会出现。输入您的用户 ID 和密码。

然后输入:

sudo ./cuda_8.0.44_linux.run

然后输入以下命令重新启动:

sudo reboot

在常规 GUI 提示符下正常登录。

如果还有问题,请在下面发表评论。

答案2

我知道这已经过去很久了,但为了帮助处于这种情况的其他人,请查看有关正在运行的 X 服务器的警告。在 Ubuntu 上,这通常意味着您应该停止 lightdm:

sudo service lightdm stop

注意:您必须在 tty shell 中执行此操作,因此您需要按 ctrl + alt + F1(或者大多数其他功能键,如果这不起作用)。

现在运行 NVIDIA 安装程序。

注意:停止 lightdm 将关闭您的 GUI,因此您需要重新启动或键入以下命令来重新启动它:

sudo service lightdm start

由于无论如何你都必须重新启动,所以这可能是不必要的,但我想你会想知道如何逆转它:)

相关内容