ubuntu 安装 nvidia 私有驱动

醉酒当歌 提交于 2019-11-27 01:17:59

部分机器安装ubuntu后无法调整到显示器最佳分辨率,首先要考虑是驱动是否正确安装。

1. 通常情况, ubuntu软件中心的驱动即可满足要求。或者 系统设置-软件和更新-附加驱动 选择相应驱动即可。

2.特殊情况,一些较好的显卡可能ubuntu适配的驱动版本过低无法使用或效果不佳,则可以尝试在nvidia官网下载相应驱动自行安装。

  我的显卡是GTX960,安装ubuntu14.04 64位后分辨率很低,且无法直接切换到tty做常规卸载和安装。在网上找了很久,总算找到了解决方法。搬运以备后用。

  原文链接 http://ubuntuforums.org/showthread.php?t=2263316

in terminal write
sudo apt-get update && sudo apt-get upgrade && sudo apt-get dist-upgrade && sudo apt-get install build-essential && sudo apt-get install linux-source && sudo apt-get install linux-headers-generic 
sudo gedit /etc/default/grub #change line "GRUB_CMDLINE_LINUX_DEFAULT..."-line to 
GRUB_CMDLINE_LINUX_DEFAULT="nouveau.blacklist=1 quiet splash nomodeset" #(forces low-level graphics to ensure putty does not give black screen)
sudo update-grub2
sudo apt-get remove nvidia* && sudo apt-get autoremove #ensures no former installation clashes with new install
sudo reboot 

After reboot get correct nvidia-driver (chose graphic-card and OS) at “http://www.nvidia.com/Download/index.aspx?lang=en-us" (or search webb with “nvidia download”). Right-click on downloaded file and change if to executable. 
sudo gedit /etc/modprobe.d/blacklist.conf #add these lines at the end:
blacklist vga16fb

blacklist nouveau
blacklist rivafb
blacklist nvidiafb
blacklist rivatv
blacklist lbm-nouveua
options nouveau modeset=0
alias nouveau off
alias lbm-nouveau off 

Open a putty-terminal with Ctrl + Alt + F1 
sudo service lightdm stop #stops graphic session to enable nvidiainstallation
cd Downloads #(or wherever you downloaded your nvidia-file)
sudo ./{the downloadedfilename.run} #follow installation-instructions (normally yes to all)sudo nvidia-xconfig #(if you did not chose “yes” to this in the installation” 
sudo nano /etc/default/grub # change the "GRUB_CMBLINE_LINUX_DEFAULT..."-line to below:
GRUB_CMDLINE_LINUX_DEFAULT="quiet splash nomodeset”
sudo update-grub2 #update grub!
sudo reboot

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!