# More nVidia woes

## Edweirdo

I have an nVidia Quadro4 700GLX.  I had it running great under my LFS system (www.linuxfromscratch.org).  I installed gentoo 1.4_rc2 and I can't seem to get the xfree to run.  I emerged the nvidia-kernel and nvidia-glx (4196).  I used the same configur[/quote]ation file from the LFS system and that doesn't work, I get a segfault.  I tried to use XFree86 -configure and it said that my nVidia card was unrecognized.  So I emerged xfree86 4.2.99 and the -configure worked, but using that configuration file gives me a "NVIDIA(0): unable to allocate config DMA context.".  I've tried to merge the two configuration files but to no availe.  I either get the above error (only appears at the console, not in the log) or I get a segfault.  You can find my XF86Config and log below:

Edmund C. Greene

ed@gztl.com

XF86Config:

 *Quote:*   

> 
> 
> Section "ServerLayout"
> 
> 	Identifier     "XFree86 Configured"
> ...

 

XFree86.0.log:

 *Quote:*   

> 
> 
> This is a pre-release version of XFree86, and is not supported in any
> 
> way.  Bugs may be reported to XFree86@XFree86.Org and patches submitted
> ...

   :Crying or Very sad: 

----------

## Supox

Hi edweirdo,

here's my config for xfree-4.2.1-r2 , nvidia-glx 1.0.4196 and 

nvidia-kernel 1.0.4191-r1

You probably want to focus on the Module and Screen size sections.

My XF86config:

 *Quote:*   

> 
> 
> Section "ServerLayout"
> 
>         Identifier     "XFree86 Configured"
> ...

 

----------

## drakonite

Try doing a "modprobe NVdriver" as root.

For some reason it won't automatically load the nvidia module into the kernel for me anymore.  I think it has something to do with that stupid f***ing "tainted kernel" message... You will get it when you modprobe, just ignore it.

----------

## drakonite

woops....  sorry.. I thought you posted a different error message... What I said probably wont' do any good for your problem... Sorry.

----------

## Narada

 *drakonite wrote:*   

> Try doing a "modprobe NVdriver" as root.
> 
> For some reason it won't automatically load the nvidia module into the kernel for me anymore.  I think it has something to do with that stupid f***ing "tainted kernel" message... You will get it when you modprobe, just ignore it.

 

In response to your problem perhaps this information taken from here will help.

 *Quote:*   

> Q: The kernel module doesn't get loaded dynamically when X starts; I always have to do 'modprobe nvidia' first.  What's wrong?
> 
> A: Make sure the line "alias char-major-195 nvidia" appears in your module configuration file, generally one of "/etc/conf.modules", "/etc/modules.conf" or "/etc/modutils/alias"; consult the documentation that came with your distribution for details.

 

----------

## Edweirdo

I definately have the module loaded, that's not the problem.

----------

## Supox

Well edweirdo,

i do know one thing for sure and that is you shouldn't load dri, xtrap and record(see module section) at all when you're using the closed binary from nvidia.

Try commenting those lines first and see if that solves it.

----------

## snutte

I have the same problem. The weird thing is when i change:

```

Option "NvAGP" "2"

```

To 3, try to startx, and then change it to 2 again. My X may start. But only every 20'th time or anything.

Seems like my nvidia modules crashes after a couple of tryes, cause this is what i get when i do a dmesg:

```

eax: 0000001b   ebx: c1d0000e   ecx: 4001b000   edx: 3ffea000

esi: f0000000   edi: f8a08aa0   ebp: f7b01ae0   esp: f7b01ae0

ds: 0018   es: 0018   ss: 0018

Process X (pid: 2386, stackpage=f7b01000)

Stack: f7b01b04 f88b8efb 4001b000 c1d0000e 00000000 00000000 f89e9e80 08000000 

       ee000000 f7b01b58 f88aafd4 f7a58000 00000000 00000000 f7a2a1a8 00000fff 

       f7a2a1b0 f7a2a1dc f7b01e64 f89ea400 00000000 bffff9c0 00000000 f7bf7e00 

Call Trace:    [<f88b8efb>] [<f89e9e80>] [<f88aafd4>] [<f89ea400>] [<f89ea400>]

  [<f88a6c4c>] [<f88bb7d7>] [<f89ea400>] [<f89ea400>] [<f88bc2d8>] [<f88bc2d8>]

  [<f89478f9>] [<c013ed76>] [<c016cd95>] [<f88bc2d8>] [<f88bc2d8>] [<c019092d>]

  [<c018f501>] [<c016aac5>] [<c016aac5>] [<c01881c5>] [<c012e49a>] [<f88a471f>]

  [<f89e9e80>] [<c0131c4e>] [<f88bb28d>] [<f89ea400>] [<f88a4afd>] [<f89ea400>]

  [<c01207b9>] [<c0244624>] [<c0163d04>] [<c0244624>] [<c01073f3>] [<c0244624>]

Code: 8b 84 82 00 00 00 c0 a8 81 74 13 89 c2 81 e2 00 f0 ff ff 89 

 0: still have vm que at nv_close(): 0x4001b000 to 0x4001c0000: still have vm que at nv_close(): 0x401a9000 to 0x401aa0000: still have vm que at nv_close():..........

```

And it continous like this for a couple of pages.

Really weird.

I have a Geforce 4 TI4200 running on my Asus p4pe (i845 chipset).

----------

## Narada

 *Supox wrote:*   

> Well edweirdo, i do know one thing for sure and that is you shouldn't load dri, xtrap and record(see module section) at all when you're using the closed binary from nvidia. Try commenting those lines first and see if that solves it.

 

I thought it was only dri and glcore that should not be used with nvidia drivers.  Why do you say xtrap and record cannot be used?  What is a good source of such information?

----------

## Edweirdo

Well, I added commented out the dri, record, and xtrap.  char-major-195 is already in my modules.conf.

Something changed, though.  I now get a black screen and on my console I have:

XIO:  fatal IO error 104 (Connection reset by peer)( on X server ":0.0"

         after 0 requests (0 known processed) with 0 events remaining.

There isn't anything interesting in my xlog.

I just don't understand why it works okay under LFS.  I would hate to reemerge X as it takes so long.

----------

## drakonite

 *Narada wrote:*   

>  *drakonite wrote:*   Try doing a "modprobe NVdriver" as root.
> 
> For some reason it won't automatically load the nvidia module into the kernel for me anymore.  I think it has something to do with that stupid f***ing "tainted kernel" message... You will get it when you modprobe, just ignore it. 
> 
> In response to your problem perhaps this information taken from here will help.
> ...

 

Nope, thats already in my modules.conf file. Thanks for the help though.

----------

## giddyup

the same thing was happening to me... my xfree86.0.log would report:

Fatal server error:

no screens found

just as your's does (i have a laptop with a Nvidia GeForce4 440 Go).  i had a valid screen defined at 1600x1200, but it refused to work at this resolution after an upgrade to xfree.  i decided to try something lower to see if i could get anything to work... i added 1024x768 to get:

```

Section "Screen"

    Identifier  "Screen 1"

    Device      "vidcard"

    Monitor     "laptop"

    DefaultDepth 24

    Subsection "Display"

        Depth       24

     Modes       "1024x768 1600x1200"

     ViewPort    0 0

    EndSubsection

EndSection

```

this fixed my problem and X ran at 1600x1200.  i can't explain it, but it works for me...

----------

## chevymoon

I'm sorry folks. I've searched and searched (I swear) for days and still no luck resolving my problem, which is the same problem so many others have had. I did an emerge -u world last week. Ever since, the nvidia drivers fail with the dreaded "no screens found" error. I have read just about every relevant post. Here is a list of my attempts to fix.

1. recompiled the kernel with MTRR support.

2. made certain that I'm using 3xxx version of the ebuild.

3. tried to modprobe NVdriver. This gives me "insmod NVdriver failed".

3. unmerged and emerged nvidia-glx and nvidia-kernel several times.

4. re-emerged xfree.

5. emerge -u world again.

6. run xf86config a dozen times, and edited the XF86Config file twice that.

No luck. Not sure where to go. I know it's a dup post. I'm at my wits end, though.

----------

## David_Escott

chevymoon i think the modules name is nvidia not NVdriver at least that is what is in my modules.autoload and from lsmod?

----------

## snutte

It seems that some of us has this problem. But I cant figure out whats causing it.

My X ran perfect until i upgraded my motherboard and cpu.

And so i decided to reinstall gentoo with my new hardware. I keept my XF86Config and so on.

So in my guess is that it has something to do with the nvidia module. But im nog certain.

But a really weird thing (Ive mentioned this a couple of times) if I try startx about twenty times. My X may start.

So its up to all of the gurus to figure this one out. Cause im to stupied to do it.   :Wink: 

----------

## chevymoon

Thanks, guys.

lsmod does not list any drivers, and modprobe nvidia says can't find driver.

----------

## chevymoon

expounding on that little revelation, does that mean my nvidia drivers aren't installed? I did an emerge nvidia-glx and emerge nvidia-kernel. Shouldn't that do it?

----------

## David_Escott

Chevymoon sorry about that aparently the name was changed with the move from 3xxx to 4xxx it is now called nvidia but for your drivers it is NVdriver. So nevermind I am just being stupid.

is /usr/sr/linux pointing to the tree where you current kernel is this is the most likely reason the module insertion would fail.

----------

## Lares

Are you using the kernel AGP drivers or the nVidia AGP Drivers?

----------

## chevymoon

David_Escott: I'm not sure, but I had not (until today, when I recompiled my kernel) done anything that I would think could affect my sources link.

Lares: I think I stumbled across something about being able to manipulate the xf86config file to select which AGP drivers are used, but I don't remember much about it at this point. Short answer: I don't know.

Thanks for your help.

----------

## Edweirdo

I don't know what might have caused my problem, but I started over and it works fine now.  I formatted my drive again and started the gentoo install from scratch.  I had to get the xfree 4.2.99 to support my card, but it is working fine now.

----------

## chevymoon

Just as a wrap up. I got it working. I'm not positive, but I think the solution is the one described in the Nvidia troubleshooter guide thingy. I had tried to rebuild my kernel, but I'm pretty sure I didn't unmerge the Nvidia ebuilds first. So, I made certain that I unmerged those, recompiled the kernel, and (after some grub issues) re-emerged the nvidia drivers. Voila! Everything was copacetic (sic).

Thanks for the help, all.

----------

## snutte

I still havent got mine to work. Think you can try to tell what you have done to get it to work? Im getting more and more angry.

----------

## David_Escott

Well the basics are as follows.

Build a kernel.

reboot.

set /usr/src/linux to point to the directory of the kernel you just booted.

emerge nvidia-kernel

modprobe (nvidia for >=4xxx) (NVdriver for <=3xxxx)

check to see it loaded with lsmod

add to modules.autoload

emerge nvidia-glx

edit your XF86Config so that the driver is nvidia not nv, remove dri, glcore, add glx, use conservative settings first too ie: NVAGP=0, "RENDERACCEL" "false" etc

(I hope Im not forgetting anything)

tell us where you have problems.

----------

## CheshireCat

```
(EE) NVIDIA(0): Failed to allocate config DMA context
```

I can't start X, I noticed that initially edweirdo had this same error when he had trouble.  I'm suspecting a kernel issue in my case, 2.4.20-gentoo-r1 has had numerous issues for me.  I can not get nvidia drivers to work with it, even after rebuilding them, I have to use pci=noacpi to make my NIC work with it, I have neither of these problems with gentoo's 2.4.19 kernels.  Also with 2.4.20, I tried to use agpgart instead of NvAGP to see if there would be any change - agpgart will not load.  I've an Athlon XP on a KT400 mobo, the gfx card is a GeForce3 Ti200, the NIC (if it matters) it a realtek 8139-based generic.  I'd be interested in knowing if anybody who has troubled getting X started w/ nvidia drivers can duplicate any of these other symptoms, or has any part of their configuration (besides an nvidia vid card, duh) in common with me.  I think there's a bug here that takes very specific combinations of drivers and hardware to trigger :-/[/quote]

----------

## CheshireCat

```
(EE) NVIDIA(0): Failed to allocate config DMA context
```

I can't start X, I noticed that initially edweirdo had this same error when he had trouble.  I'm suspecting a kernel issue in my case, 2.4.20-gentoo-r1 has had numerous issues for me.  I can not get nvidia drivers to work with it, even after rebuilding them, I have to use pci=noacpi to make my NIC work with it, I have neither of these problems with gentoo's 2.4.19 kernels.  Also with 2.4.20, I tried to use agpgart instead of NvAGP to see if there would be any change - agpgart will not load.  I've an Athlon XP on a KT400 mobo, the gfx card is a GeForce3 Ti200, the NIC (if it matters) it a realtek 8139-based generic.  I'd be interested in knowing if anybody who has troubled getting X started w/ nvidia drivers can duplicate any of these other symptoms, or has any part of their configuration (besides an nvidia vid card, duh) in common with me.  I think there's a bug here that takes very specific combinations of drivers and hardware to trigger :-/

----------

## spendabuck

why can't I load DRI with the nvidia drivers? what does it do?

 *Narada wrote:*   

>  *Supox wrote:*   Well edweirdo, i do know one thing for sure and that is you shouldn't load dri, xtrap and record(see module section) at all when you're using the closed binary from nvidia. Try commenting those lines first and see if that solves it. 
> 
> I thought it was only dri and glcore that should not be used with nvidia drivers.  Why do you say xtrap and record cannot be used?  What is a good source of such information?

 

----------

## shaniac

I'm having similar problems.

Background:  in the old days (yesterday) I had a KT266 mobo, TI4200 vidcard, and a generic realtek 8139 NIC.  No problems whatsoever.

I installed an Asus A7N8X Deluxe motherboard, lost the realtek (because there are two NICs on the MB), and now X locks my system, hard.  No Magic SysRq key.  I've tried a lot of the fixes I've seen on the forums, but no luck so far.  Still trying things, of course; isn't that what Gentoo is, a big epic adventure game with no payoff except the glorious boredom of a zippy system?!

----------

## CheshireCat

 *spendabuck wrote:*   

> why can't I load DRI with the nvidia drivers? what does it do?

 

DRI is an interface used by a number of open-source 3D drivers.  The nvidia drivers provide their own interface, so you do not need DRI to use them.  To my knowledge, there are no DRI-based drivers for nvidia cards.

----------

## shaniac

CheshireCat, I'm posting this from X!  I built a kernel from the ac-sources, emerged nvidia-driver and nvidia-glx after booting the ac kernel, and voila!  4000+ fps in glxgears!  Woo-hoo!

----------

## shaniac

CheshireCat, I'm posting this from X!  I built a kernel from the ac-sources, emerged nvidia-driver and nvidia-glx after booting the ac kernel, and voila!  4000+ fps in glxgears!  Woo-hoo!

----------

## spendabuck

 *CheshireCat wrote:*   

>  *spendabuck wrote:*   why can't I load DRI with the nvidia drivers? what does it do? 
> 
> DRI is an interface used by a number of open-source 3D drivers.  The nvidia drivers provide their own interface, so you do not need DRI to use them.  To my knowledge, there are no DRI-based drivers for nvidia cards.

 

Thanks for your reply.

----------

## squareroot

As Shaniac indicated the ac-sources work well with nvidia.  









Specifically, 2.4.21-pre4-ac7 compiled with gcc 3.2.2









( I used this to get fixes in the NForce2 IDE drivers - now merged into the AMD 74xx drivers as kernel options.)









Running gentoo 1.4-rc3 bootstrapped from stage 1 in a fresh install.  








No sign (yet) of the memory leak reported as a bug in the last three nvidia kernel modules.  







NB:  If your system is thrashing, (or compute bound in an attempt to solve storage allocation problems,) due to this bug you get serious performance problems.  This may be reported as slowdowns in moving windows, or a sticky mouse pointer.

----------

## CheshireCat

Do the current -ac sources have any XFS support?  My root is XFS, and I seem to have trouble with all of the patched kernels.  I'd also miss supermount  :Wink: 

----------

## decker in flux

This has become a horrendously muddled thread -- i cant figure out whether edwierdo has solved his problem?

I have a quadro4 700xgl , w/ a Pentium4 2.4ghz coprocessor   :Twisted Evil:   that screams in gentoo, and runs X11 w/o a hitch, send me a PM because i am scared to post here anymore ;p

-d

----------

