红联Linux门户
Linux帮助

英伟达(NVIDIA)Ubuntu显卡驱动重装

发布时间:2017-04-12 09:31:23来源:linux网站作者:kopo_C
公司新到了工作站,可是不巧被一个老外同事玩坏,显卡驱动给删除了,离变砖不远了。主管让我重装驱动,一开始觉得很简单,但死活运行不了,老是提示:
The file '/tmp/.X0-lock' exists and appears to contain the process ID '3655' of a runnning X server.
 
找了很久,饶了很多弯路,终于找到了答案,如下:
Hi I have GTX 980 Ti using Ubuntu 14.04 (I tested with GTX 970 also). I'm not sure why but installing the driver twice from different sources worked.
1.Download driver file from NVidia's website(http://www.nvidia.com/Download/index.aspx?lang=en-us), e.g. "NVIDIA-Linux-x86_64-352.55.run".
2.Firstly install from repository
run in terminal:
$ sudo apt-get remove nvidia*
$ sudo add-apt-repository ppa:xorg-edgers/ppa
$ sudo apt-get update
$ sudo apt-get install nvidia-current
3.Restart. You will find that you cannot login again. Before login, press Ctrl+Alt+F1. Enter your username and password in the command.
4.Stop the lightdm and run NVidia's install file:
run in terminal:
$ sudo stop lightdm
$ sudo cd ~/Downloads
$ sudo chmod +x NVIDIA-Linux-x86_64-352.55.run
$ sudo ./NVIDIA-Linux-x86_64-352.55.run
Here some files will be installed and in the end the program says kernel error but it's ok. Restart again, the graphic card will work.
 
简述一点,只需要kill 掉lightdm这个2b进程/服务即可。

本文永久更新地址:http://www.linuxdiyf.com/linux/29926.html