如果同意安装推荐版本,那我们只需要终端输入下面的命令就可以自动安装了
sudo ubuntu-drivers autoinstall!!!如果上述方法安装不成功
Nvidia 驱动官网
https://www.nvidia.cn/Download/index.aspx?lang=cn选择对应版本,点击搜索,页面跳转后右键点击下载,然后复制下载连接URL
我的下载链接
https://www.nvidia.cn/content/DriverDownload-March2009/confirmation.php?url=/XFree86/Linux-x86_64/450.80.02/NVIDIA-Linux-x86_64-450.80.02.run&lang=cn&type=TITAN wget XXX(XXX代表URL) sudo chmod +x NVIDIA-Linux-x86_64-450.57.run(换成自己下载的版本) sudo bash NVIDIA-Linux-x86_64-450.57.run --no-opengl-files(换成自己下载的版本)!!PS:–no-opengl-files 只安装驱动文件,不安装OpenGL文件,这个参数最重要。
如果在安装过程中提示缺少gcc,make…依赖的包,只需要
sudo apt-get install gcc sudo apt-get install make(如果还缺少别的依赖包,自己安装即可)安装过程中的一些选项:
The distribution-provided pre-install script failed! Are you sure you want to continue? 选择 yes 继续。Would you like to register the kernel module souces with DKMS? This will allow DKMS to automatically build a new module, if you install a different kernel later? 选择 No继续。问题大概是:Nvidia’s 32-bit compatibility libraries? 选择 No 继续。Would you like to run the nvidia-xconfigutility to automatically update your x configuration so that the NVIDIA x driver will be used when you restart x? Any pre-existing x confile will be backed up. 选择 Yes 继续。!!!!上述安装步骤是自己在安装过程中参考了部分资料并总结的,不一定全部适用,仅供参考