免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 2152 | 回复: 2
打印 上一主题 下一主题

linux下安装官方nvidia和ATI显卡驱动步骤 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2008-10-31 13:59 |只看该作者 |倒序浏览
注:我的系统是ubuntu 8.04
NVIDIA:
    1. 到
http://www.nvidia.com/
下载驱动
    2. 删除原来的驱动(如果你装过驱动)
    sudo apt-get --purge remove nvidia-glx
    sudo apt-get --purge remove nvidia-settings nvidia-kernel-commonsudo
    rm /etc/init.d/nvidia-*
    3. 备份当前的显示设置,这样可以在驱动安装失败时恢复到原来的设置
    sudo cp /etc/X11/xorg.conf /etc/X11/xorg.conf.backup
    4. 安装驱动程序编译环境
    sudo apt-get install build-essential linux-headers-`uname -r`
    5. 禁止系统使用默认的驱动
    sudo gedit /etc/default/linux-restricted-modules-common
    在最后的双引号中添加nv,即“”改成“nv”
    6. 按Ctrl+Alt+F1,登录,停止gdm或kdm
    sudo /etc/init.d/gdm(kdm) stop
    7. 进入下载的驱动安装文件 nvidia-linux-x86-1.0-9631-pkg1.run所在目录(请确定xorg-dev软件包已经安装,编译过程中可能会用到)
    sudo sh nvidia-linux-x86-*.run
    如果提示缺少某某模块(modules),询问是否上网下载,选no;
    8. 安装完成后,启动gdm
    sudo /etc/init.d/gdm start
对宽屏来说,此时可能需要改变分辨率,在UBUNTU中,选择菜单“应用程序”─“系统工具”─“NVIDIA X Server Settings”,进入便可以改变分辨率;
同时要修改/etc/X11/xorg.conf文件,把里面的1024x768都修改为你选择的分辨率:
sudo gedit /etc/X11/xorg.conf
打开修改就可以了。
在这两处都修改才能保证每次重新启动后分辨率不会改回到原来的1024x768.

Section "Device"
    Identifier     "Videocard0"
    Driver         "nvidia"
    VendorName     "NVIDIA Corporation"
    BoardName      "GeForce Go 6600"
    Option         "NoLogo"
EndSection
Section "Screen"
    Identifier     "Screen0"
    Device         "Videocard0"
    Monitor        "Monitor0"
    DefaultDepth    24
    Option         "metamodes" "1024x768_60 +0+0; 800x600 +0+0; 640x480 +0+0"
    SubSection     "Display"
        Depth       24
        Modes      "1600x1200" "1280x1024" "1024x768" "800x600" "640x480"
    EndSubSection
EndSection

安装好后如果没有问题了,可以进行一下3D性能优化:
下面是我的优化配置和简单的注释:
# For NVIDIA's platform to function correctly, you must 32 bit ARGB GLX Visuals
# 这个选项是N卡必须的
Option "AddARGBGLXVisuals" "True"
# This option is not really needed with newer drivers as it is enabled by default at 9746 and newer.
# 9746版本以下的驱动才需要,以上的驱动默认已打开
Option "RenderAccel" "True"
# This option helps performance. It is currently incompatible with SLI and MultiGPU modes.
# 改善性能,但是不兼容SLI和MultiGPU
Option "DamageEvents" "True"
# Use this option with caution as it may not work on all systems.
# 如果出问题,就把本优化项去掉
Option "UseEvents" "False"
# Do NOT use this option if you have less than 128mb vram and always with Sync2Vblank enabled at nvidia-settings both for OpenGL and XV.
# 如果你的显存小于128M而且在nvidia-settings程序中为OpenGL和XV两者打开了Sync2Vblank,就不要使用本选项
Option "TripleBuffer" "True"
#Use this options with caution as it may not work on all systems, especially with 6 series GeForce cards (it is known to cause freezes with compiz) but give it a try because it helps performance. It can also break Xinerama.
# 在6系列显卡上不要打开本选项,其他显卡打开看看能不能改善性能
# Option "BackingStore" "True"
# 启动xserver时不显示NVidia的Logo
Option "NoLogo"
ATI:
1.首先删除旧的驱动
sudo apt-get remove--purgefglrx-control
sudo apt-get remove--purgefglrx-kernel-source
sudo apt-get remove--purgexorg-driver-fglrx
sudo lrm-manager
2.并把原来装过的4个包彻底删除。
sudo apt-get autoremove --purge fglrx*
3.更新和安装一些关联包
sudo apt-get update
sudo apt-get install build-essential fakeroot dh-make debhelper debconf libstdc++5 dkms
4.安装(你也可以关掉X server再安装)
  A.编译出deb安装包然后安装
  bash *.run --buildpkg Ubuntu/hardy
  #可能缺个so,那就:sudo ln -s /usr/lib/libGL.so /usr/lib/libGL.so.1
  #屏蔽fglrx核心模块
  sudo gedit /etc/default/linux-restricted-modules-common
  将DISABLED_MODULES="" 改为DISABLED_MODULES="fglrx"
  #如果/etc/modprobe.d/blacklist-restricted文件存在,那么需要代码:
  sudo nano /etc/modprobe.d/blacklist-restricted  并把blacklist fglrx用#注释掉。
  #安装deb包
  sudo dpkg -i xorg-driver-fglrx_*.deb fglrx-kernel-source*.deb fglrx-amdcccle*.deb
  B.直接安装(不建议)
  sudo sh *.run
5.配置后重启
  sudo aticonfig --initial -f
sudo gedit /etc/X11/xorg.conf 确保Section "Device"那段有Driver "fglrx"
确认驱动是否正确安装(可以类似于)fglrxinfo


本文来自ChinaUnix博客,如果查看原文请点:http://blog.chinaunix.net/u2/81801/showart_1355495.html

论坛徽章:
0
2 [报告]
发表于 2012-10-18 22:57 |只看该作者
请教楼主,若在NVIDIA X Server Settings里面选择不到合适的分辨率,可能是什么原因呢?

论坛徽章:
0
3 [报告]
发表于 2012-11-08 22:41 |只看该作者
回复 1# morneve


    很好,很细,我的是集成X3100显卡,不会安装驱动,解决不了宽屏问题,要是也有这样的例子就好了。
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP