QQ登录

只需一步,快速开始

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 3642|回复: 15

2.6.4内核编译成功,但显卡配置出错,不能进图形界面!!!

[复制链接]
发表于 2004-4-16 01:22:04 | 显示全部楼层 |阅读模式
编译完成后进入新内核时,启动过程只有USB的几个选项启动失败了,其他全是OK。但最后一步,进不了图形界面,就像以前卸载显卡驱动的情况一样,所以决定装显卡驱动,NVIDIA-Linux-x86-1.0-5336-pkg1.run这个是在公社里下的,说是针对2.6.4内核的。
于是sh NVIDIA-Linux-x86-1.0-5336-pkg1.run
出现提示,说已经发现一个旧的驱动1.0-4496存在(我在原来的内核下装的NVIDIA-Linux-x86-1.0-4496-pkg2.run),是否卸载旧的来安装新的驱动。
选择“yes”然后等了一下,出现下面的提示
“No precompiled kernel interface was found to match your kernel”接下还问是否down a kernel interface for your kerne from NVIDIA的官方网站,我选“YES”结果提示联网失败,然后又出现一段提示
“No matching precompiled kernel interface was found on the NVIDIA ftp site;this means that the installer will need to compile a kernel interface for your kernel”
然后选“OK”开始进入“Building kernel module”界面,等进度条走完后,提示安装完成。
然后我打startx命令,屏幕只是闪了几下,又出现一大堆E文,我挑了几条主要的内容,其中第一条提示是到www.xfree86.org下载最新的版本。
后面的“Screen(s) found ,but none have a usable configuration.”
再下面的是:
     "Fatal servers error:         no screens found"
还有“XIO:fatal IO error 104(Connection reset by peer) on X     server":0.0"
after 0 requests(0 known processed)
with 0 events remaining

大致就是这些了,大家有没有见过这个情况,还请高手解决,不知道是不是我没有编译好?



PS:我的新内核里的RPM命令也不能用:(。
发表于 2004-4-16 11:12:30 | 显示全部楼层
哈哈,我也遇到这个问题了,我是这样解决的。先从官方网站下载5336驱动,然后看里面的README按提示加一个参数将源代码解压缩,找到显卡驱动的代码尝试编译,肯定不通过
但是可以看见系统提示少什么库文件,想办法将该库文件安装上,此时再按普通方法来安装驱动
就好了,但是要注意如果使用2.6.x的内核必须要安装新的模块工具。
安装好以后再修改配置文件将“nv"处改为"nvidia"就可以了,
当让本人比较笨,每次都要用 insmod /lib/modules/.../vedio/nvidia/nvidia.ko来加载模块
才能使用xfree86好痛苦
回复

使用道具 举报

发表于 2004-4-16 18:23:44 | 显示全部楼层
你忘了修改 /etc/X11/XF86Config ???
回复

使用道具 举报

 楼主| 发表于 2004-4-17 21:23:38 | 显示全部楼层
回:jiangtao9999

这个文件在旧内核里就修改好了,我在新内核下查看时和原来改好的一样,不需要在修改了。
回复

使用道具 举报

 楼主| 发表于 2004-4-17 21:28:35 | 显示全部楼层
回:llemmx

兄弟,能不能说详细一点啊,看哪里的README啊?我下的驱动就只是一个可执行文件,不需要解压的。
你说的要加参数解压的是什么压缩包啊,.src.rpm吗??
帮帮我吧,我都快急死了!!!!
回复

使用道具 举报

发表于 2004-4-18 10:04:43 | 显示全部楼层
先运行一下
modprobe nvidia
回复

使用道具 举报

发表于 2004-4-18 14:20:18 | 显示全部楼层
[code:1]
[root@fudaming NVIDIA-Linux-x86-1.0-5336-pkg1]# make install
cd usr/src/nv; make install
make[1]: Entering directory `/root/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv'
echo \#define NV_COMPILER \"`cc -v 2>&1 | tail -n 1`\" > /root/NVIDIA-Linux-x86- 1.0-5336-pkg1/usr/src/nv/nv_compiler.h
  CC [M]  /root/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.o
In file included from include/linux/list.h:7,
                 from include/linux/wait.h:14,
                 from include/asm/semaphore.h:41,
                 from include/linux/sched.h:18,
                 from include/linux/module.h:10,
                 from /root/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv-linux.h :52,
                 from /root/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:14:
include/linux/prefetch.h: In function `prefetch_range':
include/linux/prefetch.h:62: warning: pointer of type `void *' used in arithmeti c
/root/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c: At top level:
/root/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:1185: warning: initializati on from incompatible pointer type
  CC [M]  /root/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/os-agp.o
In file included from include/linux/list.h:7,
                 from include/linux/wait.h:14,
                 from include/asm/semaphore.h:41,
                 from include/linux/sched.h:18,
                 from include/linux/module.h:10,
                 from /root/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv-linux.h :52,
                 from /root/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/os-agp.c:2 4:
include/linux/prefetch.h: In function `prefetch_range':
include/linux/prefetch.h:62: warning: pointer of type `void *' used in arithmeti c
  CC [M]  /root/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/os-interface.o
In file included from include/linux/list.h:7,
                 from include/linux/wait.h:14,
                 from include/asm/semaphore.h:41,
                 from include/linux/sched.h:18,
                 from include/linux/module.h:10,
                 from /root/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv-linux.h :52,
                 from /root/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/os-interfa ce.c:26:
include/linux/prefetch.h: In function `prefetch_range':
include/linux/prefetch.h:62: warning: pointer of type `void *' used in arithmeti c
  CC [M]  /root/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/os-registry.o
In file included from include/linux/list.h:7,
                 from include/linux/wait.h:14,
                 from include/asm/semaphore.h:41,
                 from include/linux/sched.h:18,
                 from include/linux/module.h:10,
                 from /root/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv-linux.h :52,
                 from /root/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/os-registr y.c:14:
include/linux/prefetch.h: In function `prefetch_range':
include/linux/prefetch.h:62: warning: pointer of type `void *' used in arithmeti c
  LD [M]  /root/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nvidia.o
  Building modules, stage 2.
  MODPOST
/lib/modules/2.6.5-1.326/build/Module.symvers: No such file or directory
make[4]: *** [__modpost] ?? 134
make[3]: *** [modules] 错误 2
nvidia.ko failed to build!
make[2]: *** [module] 错误 1
make[1]: *** [install] 错误 2
make[1]: Leaving directory `/root/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv'
make: *** [kernel_module_install] 错误 2
[root@fudaming NVIDIA-Linux-x86-1.0-5336-pkg1]#
[/code:1]

[code:1]
nvidia-installer log file '/var/log/nvidia-installer.log'
creation time: Sat Apr 17 19:54:20 2004

option status:
  license pre-accepted    : false
  update                  : false
  force update            : false
  expert                  : false
  uninstall               : false
  driver info             : false
  no precompiled interface: false
  no ncurses color        : false
  query latest driver ver : false
  OpenGL header files     : false
  no questions            : false
  silent                  : false
  XFree86 install prefix  : /usr/X11R6
  OpenGL install prefix   : /usr
  Installer install prefix: /usr
  kernel source path      : (not specified)
  kernel install path     : (not specified)
  proc mount point        : /proc
  ui                      : (not specified)
  tmpdir                  : /tmp
  ftp site                : ftp://download.nvidia.com

Using: nvidia-installer ncurses user interface
-> License accepted.
-> No precompiled kernel interface was found to match your kernel; would you li
   ke the installer to attempt to download a kernel interface for your kernel f
   rom the NVIDIA ftp site (ftp://download.nvidia.com)? (Answer: Yes)
-> No matching precompiled kernel interface was found on the NVIDIA ftp site;
   this means that the installer will need to compile a kernel interface for
   your kernel.
-> Kernel source path: '/lib/modules/2.6.5-1.326/build'
-> Performing cc_version_check with CC="cc".
-> Cleaning kernel module build directory.
   executing: 'cd ./usr/src/nv; make clean'...
   rm -f -f nv.o os-agp.o os-interface.o os-registry.o nv.o os-agp.o os-interfa
   ce.o os-registry.o nvidia.mod.o
   rm -f -f build-in.o nv-linux.o *.d .*.{cmd,flags}
   rm -f -f nvidia.{o,ko,mod.{o,c}} nv_compiler.h *~
-> Building kernel module:
   executing: 'cd ./usr/src/nv; make module SYSSRC=/lib/modules/2.6.5-1.326/bui
   ld'...
   echo \#define NV_COMPILER \"`cc -v 2>&1 | tail -n 1`\" > /tmp/selfgz1303/NVI
   DIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv_compiler.h
     CC [M]  /tmp/selfgz1303/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.o
   In file included from include/linux/list.h:7,
                    from include/linux/wait.h:14,
                    from include/asm/semaphore.h:41,
                    from include/linux/sched.h:18,
                    from include/linux/module.h:10,
                    from /tmp/selfgz1303/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src
   /nv/nv-linux.h:52,
                    from /tmp/selfgz1303/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src
   /nv/nv.c:14:
   include/linux/prefetch.h: In function `prefetch_range':
   include/linux/prefetch.h:62: warning: pointer of type `void *' used in arith
   metic
   /tmp/selfgz1303/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c: At top level
   :
   /tmp/selfgz1303/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nv.c:1185: warning
   : initialization from incompatible pointer type
     CC [M]  /tmp/selfgz1303/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/os-agp.o
   In file included from include/linux/list.h:7,
                    from include/linux/wait.h:14,
                    from include/asm/semaphore.h:41,
                    from include/linux/sched.h:18,
                    from include/linux/module.h:10,
                    from /tmp/selfgz1303/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src
   /nv/nv-linux.h:52,
                    from /tmp/selfgz1303/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src
   /nv/os-agp.c:24:
   include/linux/prefetch.h: In function `prefetch_range':
   include/linux/prefetch.h:62: warning: pointer of type `void *' used in arith
   metic
     CC [M]  /tmp/selfgz1303/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/os-inter
   face.o
   In file included from include/linux/list.h:7,
                    from include/linux/wait.h:14,
                    from include/asm/semaphore.h:41,
                    from include/linux/sched.h:18,
                    from include/linux/module.h:10,
                    from /tmp/selfgz1303/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src
   /nv/nv-linux.h:52,
                    from /tmp/selfgz1303/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src
   /nv/os-interface.c:26:
   include/linux/prefetch.h: In function `prefetch_range':
   include/linux/prefetch.h:62: warning: pointer of type `void *' used in arith
   metic
     CC [M]  /tmp/selfgz1303/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/os-regis
   try.o
   In file included from include/linux/list.h:7,
                    from include/linux/wait.h:14,
                    from include/asm/semaphore.h:41,
                    from include/linux/sched.h:18,
                    from include/linux/module.h:10,
                    from /tmp/selfgz1303/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src
   /nv/nv-linux.h:52,
                    from /tmp/selfgz1303/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src
   /nv/os-registry.c:14:
   include/linux/prefetch.h: In function `prefetch_range':
   include/linux/prefetch.h:62: warning: pointer of type `void *' used in arith
   metic
     LD [M]  /tmp/selfgz1303/NVIDIA-Linux-x86-1.0-5336-pkg1/usr/src/nv/nvidia.o
     Building modules, stage 2.
     MODPOST
   /lib/modules/2.6.5-1.326/build/Module.symvers: No such file or directory
   make[3]: *** [__modpost] ?? 134
   make[2]: *** [modules] 错误 2
   nvidia.ko failed to build!
   make[1]: *** [module] 错误 1
   make: *** [module] 错误 2
-> Error.
ERROR: Unable to build the NVIDIA kernel module.
ERROR: Installation has failed.  Please see the file
       '/var/log/nvidia-installer.log' for details.  You may find suggestions
       on fixing installation problems in the README available on the Linux
       driver download page at www.nvidia.com.
[/code:1]
回复

使用道具 举报

发表于 2004-4-18 14:22:56 | 显示全部楼层
[root@fudaming root]# uname -a
Linux fudaming 2.6.5-1.326 #1 Thu Apr 15 08:40:14 EDT 2004 i686 athlon i386 GNU/Linux
系统是fedora2 test2 kernel#2.6.5-1.322_2.6.5-1.326_i686.rpm

哪位大哥救救我,多谢了。
回复

使用道具 举报

发表于 2004-4-18 16:27:11 | 显示全部楼层
fudaming, 开发包装全了么?
回复

使用道具 举报

发表于 2004-4-18 17:47:08 | 显示全部楼层
选的是全部安装,一共5个多G。
回复

使用道具 举报

发表于 2004-4-18 18:36:10 | 显示全部楼层
重新编译了一遍kernel,在源码目录下发现了这个缺的文件Module.symvers,本来是没有的。copy到/lib/modules/2.6.5-1.326/build/
nv驱动编译成功,但是不能进入X,黑屏,键盘失去响应,没有办法,直接按机箱上的重启。可能是网上说的bug,尝试使用CONFIG_REGPARM=n +  CONFIG_4KSTACKS=n 选项。编译中。
回复

使用道具 举报

发表于 2004-4-20 22:56:44 | 显示全部楼层
我看还是把nvidia改成nv用着再说吧
回复

使用道具 举报

发表于 2004-4-21 10:06:26 | 显示全部楼层
说的也是,安装失败了。
回复

使用道具 举报

发表于 2004-4-23 23:57:21 | 显示全部楼层
我的fedora core 2 test2装上显卡驱动后再进X的时候也是黑屏
我把X统统干掉,然后自己编译
再编译内核
重新安装nvidia的显卡驱动后就可以进入X了
速度有不少的提高
回复

使用道具 举报

发表于 2004-7-11 01:24:06 | 显示全部楼层
InstallationHere are the instructions for building and installing your nVidia drivers, the Debian way.
Overview
The nVidia driver consists of two parts: a kernel module, and a collection of user-space libraries. The libraries (aka the "binary driver" or GLX libraries) are distributed in binary form by nVidia, and packaged for Debian in the nvidia-glx package. The kernel module (aka the "kernel interface to the binary driver") is distributed in source form (though with one binary component), and packaged for Debian in the nvidia-kernel-source and nvidia-kernel-common packages. The user libraries and kernel module source only have to be installed once. Then the kernel module has to be rebuilt every time you rebuild your kernel. So, here's what you will do:
Install the kernel module source.
Build and install the kernel and kernel module.
Install the user-space libraries.
Update your configuration.
Step 1 used to require some patching if you were running kernel 2.6, but that's no longer necessary. Step 3 has to be performed after step 2 because of some dependencies, as I explain below.

Steps 1, 3, and 4 have to be performed only once. Step 2 you have to repeat every time you rebuild your kernel, but with make-kpkg and dpkg, it's hardly any work at all.

Installation Instructions
Before you install the Debian nVidia packages, you should choose a distribution, either 'testing' or 'unstable', from which to install them. There is no 'stable' version of these packages at present. At this writing, the nVidia packages in testing and unstable are the same, version 1.0.5336. So for now there's no difference. However the choice you make may affect how your packages get updated in the future, as later versions become available.
Once you've chosen a distribution, put its value into a shell variable NVDIST, by executing one of the following lines:

NVDIST=testing
NVDIST=unstable

I will use $NVDIST to represent this value in all of the commands below. Also, make sure that your /etc/apt/sources.list contains a line like 'deb http://http.us.debian.org/debian $NVDIST main contrib non-free', for your $NVDIST. And if you've just added that line, you need to run 'apt-get update' before continuing below.
Install the kernel module source.
Install the source archive: run
apt-get -t $NVDIST install nvidia-kernel-source nvidia-kernel-common

This will give you a source tarball /usr/src/nvidia-kernel-source.tar.gz.
Unpack the source archive:
cd /usr/src
tar -zxf nvidia-kernel-source.tar.gz

This will unpack the kernel module sources into /usr/src/modules/nvidia-kernel.
Build and install the kernel and kernel module.
Configure your kernel. I won't try to document this step here; if you need to learn how, see the Kernel HOWTO and "How to Upgrade to the 2.6 Kernel". But in summary, all you have to do is
cd /usr/src/linux
make xconfig


and then choose the options you want.
Build the kernel and nvidia kernel module:
cd /usr/src/linux
make-kpkg clean kernel_image modules_image

If you're not familiar with make-kpkg, see "Compiling Kernels the Debian Way" for an introduction. See also the make-kpkg man page, for a description of other options and targets that you can use in this command.
The result of the above command will be two Debian package files, kernel-image-*.deb and nvidia-kernel-*.deb, both in /usr/src. The first file contains your kernel, and the second contains your nVidia kernel module.

At the same time, if you've unpacked the sources for any other add-on kernel modules in /usr/src/modules, then the "modules_image" target will cause make-kpkg to build Debian package files for them, too. For example, the lm-sensors-source package gives you a source archive which, when unpacked, puts the lm-sensors modules sources into /usr/src/modules/lm-sensors. The lm-sensors modules package would get built at the same time, if it worked with kernel 2.6 (which, the last time I looked, it doesn't—sorry).

Install the new kernel and kernel module:
cd /usr/src
dpkg -i kernel-image-*.deb nvidia-kernel-*.deb

Use the fileglobs as above if you want, but watch out that you don't have more than one kernel-image or nvidia-kernel package file lying around in /usr/src. If you do you'll get a blizzard of error messages. It's probably better to explicitly type all of the version information that I rendered as * above.
Install the nVidia user-space libraries. Run
apt-get -t $NVDIST install nvidia-glx

If you're asked whether you want to install the thread-local storage libraries, say yes. Notes:
If your libc6 package is from the stable distribution, then you'll have to upgrade it to testing/unstable in order to complete this step. apt-get will prompt you to do this, and you may have to resolve some conflicts first. libc6 is a core component of GNU/Linux, so if you're running a production server, you may not want to use the version from testing. But for most of us, there shouldn't be any problem. I've been using libc6 from testing for several months now, and found only one minor bug.
If the kernel you installed above is version 2.6.x, and the one you're running now is pre-2.6, then you should reboot with your new kernel before performing this step. The reason is that if you're not running a 2.6-series kernel when you perform this step, the thread-local storage part of the user-space libraries will not be installed. As a result your X server will crash when it tries to load the nVidia driver. If you already installed nvidia-glx earlier under a pre-2.6 kernel, then you can either uninstall and reinstall it while running the new kernel, or, more simply, run 'dpkg-reconfigure nvidia-glx'.
The reason this step has to come after step 2 is that nvidia-glx depends on a virtual package called 'nvidia-kernel-$NVVERSION', where $NVVERSION is the version number of the nVidia driver you've installed. This virtual package is provided by the kernel module package that you built and installed in step 2; so you have to complete that step first.
Update your configuration.
Edit /etc/X11/XF86Config-4:
In the "Modules" section, be sure that you have a line
Load "glx"

and remove or comment out (prepend with a #) any lines that refer to the "dri" or "GLCore" modules.
In the "Device" section for your video card, be sure you have a line
Driver "nvidia"

An open-source alternative is the "nv" driver, which has more limited capabilities.
Create a "video" group, and add to it any users who you want to be able to use the display. You can do this by manually editing /etc/group, or by
addgroup --system video
adduser $USER video

That's it. Your binary driver and kernel interface module are now installed, and should work when you reboot with the new kernel and/or restart your X server. Notes:

For more information about the driver, see:
/usr/share/doc/nvidia-glx/README.Debian
/usr/share/doc/nvidia-glx/README.gz
/usr/share/doc/nvidia-kernel-source/README.Debian
These files contain a lot of useful information about driver options and troubleshooting. Here's an enticement for you to read them: somewhere in one of them you can find an explanation of how to suppress the nVidia splash screen every time you start an X server (hint: search for "NoLogo").
As I said above, you won't ever have to repeat steps 1, 3, and 4 above, as long as you don't uninstall nvidia-glx or change the contents of /usr/src/modules/nvidia-kernel (e.g. by upgrading your driver source).
The kernel module that you built in step 2 is specific to the kernel you built it with. If you rebuild your kernel for any reason, you'll have to compile a new driver module to go with it. But that's what the instructions above tell you to do; if you follow them you should be fine.
Using this method, you don't need any of the following things:
The official nVidia installer from nvidia.com. (The Debian packages contain all the parts of it that you need.)
Any of the patch or installer files available at minion.de. (But thanks to the folks at minion.de for providing those patches, for all of the time when the official nVidia drivers didn't work yet with kernel 2.6.)
The nvidia-kernel-src and nvidia-glx-src packages, which are deprecated. You can also ignore the nvidia-glx-dev package, unless you get complaints from some software (old games?) about missing libGL.so (thanks to Randall Donald for this information).
You can ignore the warning at www.minion.de about carrying along the EXTRAVERSION information if you use --append-to-version with make-kpkg. Because you're using make-kpkg all the way through the build process, it takes care of this for you.
Last updated: 2004-Apr-16 at 16:51
Viewed times since February 18, 2004
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

GMT+8, 2024-8-30 05:06 , Processed in 0.084976 second(s), 15 queries .

© 2021 Powered by Discuz! X3.5.

快速回复 返回顶部 返回列表