Go Back   nV News Forums > Linux Support Forums > General Linux

Newegg Daily Deals

Reply
 
Thread Tools
Old 11-22-02, 02:35 PM   #13
Chalnoth
Registered User
 
Join Date: Jul 2002
Posts: 1,293
Default

Quote:
Originally posted by lunix
Chanloth it is not a memory leak. What is happening is that X is mmaping your AGP aparature and adding your graphics card memory as allocated memory. When top asks how much memory each application is using X reports way more memory than it is actually using skewing the results.
I'll look into this, but I wasn't entirely referring to the absolute memory usage being used to detect whether or not there was a memory leak. Anyway, I think I may have thought of a way to get my nForce2 sound to work, but it's going to take some time...so I'm not going to work on it just yet...once I do, though, I'll deal with this issue.
Chalnoth is offline   Reply With Quote
Old 11-22-02, 08:22 PM   #14
lunix
Registered User
 
lunix's Avatar
 
Join Date: Jul 2002
Location: Vancouver
Posts: 69
Send a message via MSN to lunix
Default

Run top and press "M" to sort by memory to help diagnose the leaking app. Beyond that its arcane arts reserved for developers. Anyhow looking into it you will find that the mmaped buffers in X with 3D acceleration seriously screw your memory readings.
To bad about the pauses in ut must be anoying. Perhaps you could try changing agp drivers from nvagp to agpgart but Im just guessing here. It would be strange for linux to swap out an app that is in use, I know the vm sucks but not that bad. Good luck and have fun Chalnoth.
__________________
Gentoo
lunix is offline   Reply With Quote
Old 11-23-02, 09:16 PM   #15
Chalnoth
Registered User
 
Join Date: Jul 2002
Posts: 1,293
Default

I don't think it would need to swap out an app in use to slow down the program. Swapping anything could slow down the system. Anyway, I'm now trying to get the R9700 to work in Linux. It's interesting...agpgart won't recognize my nForce2, so x won't start using ATI's drivers.

Update:
Hrm, that brings up a possibly different problem. The stuttering would definitely be more pronounced if DMA was disabled. I checked /proc/ide/hda/settings
Under "Using dma" there was a value of 0.

Do you know how to enable DMA?

Last edited by Chalnoth; 11-23-02 at 09:36 PM.
Chalnoth is offline   Reply With Quote
Old 11-24-02, 12:18 AM   #16
Phyre
Registered User
 
Phyre's Avatar
 
Join Date: Jul 2002
Location: Central Louisiana
Posts: 323
Default

Chalnoth, check out the hdparm command. It's in /sbin, so you might have to invoke it with /sbin/hdparm. As root (su), run this command to see what kind of rates you're getting:

/sbin/hdparm -Tt /dev/hdx (where x is your linux drive).

To enable DMA, su and type /sbin/hdparm -d1 /dev/hdx. There are other things you can to do with hdparm to boost the performance of your drive too. This might help ya out in that respect.

http://www.linuxnetmag.com/en/issue7/m7hdparm1.html

Once you have the settings that you need for your drive, you can put them in your rc.d file so that they will load every time. Can't remember exactly which rc.d file. I have to do a search on it everytime I reinstall. LOL

Also, what motherboard/chipset are you using. I'm not sure if it's been fixed in RedHat 8, but VIA used to have problems with not beeing able to get to ATA100 modes. The source for it's module had to be modified a bit, hence forcing a rebuild of the kernel.

Hope this gets you a little further into this caper.

Phyre
Phyre is offline   Reply With Quote
Old 11-24-02, 01:08 AM   #17
lunix
Registered User
 
lunix's Avatar
 
Join Date: Jul 2002
Location: Vancouver
Posts: 69
Send a message via MSN to lunix
Default

You can make sure your drive are configured by adding the autotune option for you kernel. e.g. my /boot/grub/menu.lst has the following options for my kernel:

title=Gentoo Linux
root (hd0,1)
kernel /boot/bzImage vga=791 root=/dev/hda2 ide0=autotune ide1=autotune ide3=autotune acpi=no-idle hdc=ide-scsi
__________________
Gentoo
lunix is offline   Reply With Quote
Old 11-24-02, 01:51 AM   #18
Chalnoth
Registered User
 
Join Date: Jul 2002
Posts: 1,293
Default

Thanks for the replies. Investigating now...

I'm using an nForce2 motherboard, and here are the hdparm -Tt /dev/hda results:

buffer-cache: 304MB/sec
buffered-disk: 3.29MB/sec

(Disk is IBM 75GXP...reads should max out at somewhere close to 30MB/sec sustained...)

Update:
Oh, yeah, the hdparm -d1 /dev/hda definitely worked.

buffer-cache: 298MB/sec
buffered-disk: 31.22MB/sec

Update #2:
I went ahead and inserted the commands (for HD and DVD/CD-RW drives into the rc.local file, and now it all works great. Thanks again

Last edited by Chalnoth; 11-24-02 at 02:06 AM.
Chalnoth is offline   Reply With Quote
Old 11-24-02, 02:35 AM   #19
Chalnoth
Registered User
 
Join Date: Jul 2002
Posts: 1,293
Default

Oh, and one last little thing.

With UT, the major suttering I got previously has dropped back to very minor pauses. They're now bearable, but shouldn't be there at all. Anybody know where I can configure the cache in Linux?
Chalnoth is offline   Reply With Quote
Old 11-24-02, 11:21 AM   #20
kappax
Registered User
 
Join Date: Oct 2002
Posts: 56
Default

Quote:
Originally posted by Chalnoth
Update:

One other thing, I'm not actually completely convinced there isn't a memory leak going on. Even taking the cache/buffer into account, memory usage is way above what it seems it should be.

For example, you're showing about 110MB of memory in use. Running rather few programs, I was showing about 140MB (cache taken into account). Anyway, I guess I'll have to do a more in-depth analysis to be certain. I suppose I'll do that later.
I would like to know whaty you mean by this

" I was showing about 140MB (cache taken into account)."

plez dont start adding numbers.

used is used
460308k used
free is free
54812k free
cached is cached
181568k cached

each one means someting.


post us what you see when you type "top" at a console.
kappax is offline   Reply With Quote

Old 11-24-02, 11:32 AM   #21
kappax
Registered User
 
Join Date: Oct 2002
Posts: 56
Default

Quote:
Originally posted by Chalnoth
Oh, and one last little thing.

With UT, the major suttering I got previously has dropped back to very minor pauses. They're now bearable, but shouldn't be there at all. Anybody know where I can configure the cache in Linux?
the cache does not cause you to swap!

And second, I still dont even know how much ram you have !!


effectiv free meme
free + cached = free

when someitng needs ram it will clear out the cache (part of ot not all of it ) and make roome for the new program needing to be run.

Second Ut2003 is a real real real hard game on computers.
I dont know your computer specks but pausing now and this can be related to

misconfigured vid card.
bad IDE setings (seems you fixed thoes)
misconfigured or bad sound card drivers (try turning it to HW accel insted of default sound settings )

what sort of FPS are you getting ?


what system do you have ? vid card amount of ram ? ddr ? sound card ?


we know nothing about your system.



oh to configure the cache you would have to rewrite part of your kernel. ( as far as i know)

you rellay should not need to mess with the cache.


Sounds like you are running a older distro, or a distro that has not optmized there kernel

you need to look in to getting a kernel with
eather
preimpt+low late
or one with preimpt
or one with low late

if you use other patches on your kernel it will be hard to incoperate both preimpt and lowlate, but low late i think is the best otheres think preimpt is.

I have had a kernel with lowlate and preimpt but my drivers for my ide card have made it to where i can only use low late.
kappax is offline   Reply With Quote
Old 11-24-02, 11:51 AM   #22
Chalnoth
Registered User
 
Join Date: Jul 2002
Posts: 1,293
Default

Quote:
Originally posted by kappax
the cache does not cause you to swap!
Um. I'm getting swapping with cache still in use (~100MB or so of cache in use). I have 256MB of RAM.

Quote:
when someitng needs ram it will clear out the cache (part of ot not all of it ) and make roome for the new program needing to be run.
Right. What I'm apparently seeing is that the cache isn't being cleared out quickly enough, and a little bit is being written to swap to clear out the necessary memory (Generally 200k-500k at a time).

While this could be an optimization issue (whatever is being written to swap is most probably not something that's been used recently), I'd rather that the cache is cleared instead of writing things to swap.

Quote:
Second Ut2003 is a real real real hard game on computers.
I dont know your computer specks but pausing now and this can be related to

misconfigured vid card.
bad IDE setings (seems you fixed thoes)
misconfigured or bad sound card drivers (try turning it to HW accel insted of default sound settings )
Athlon XP 2000+
nForce2
GeForce4 Ti 4200

Anyway, even if the IDE settings were bad, they should not have ever affected in-game performance. There shouldn't be anything writing to the HD while I'm playing.

I haven't checked the FPS, but I'll have to get back to you on that (in windows atm).

It is conceivable that it's the sound drivers. I'll have to look into that some more.

Quote:
Sounds like you are running a older distro, or a distro that has not optmized there kernel
Redhat 7.3
Chalnoth is offline   Reply With Quote
Old 11-25-02, 01:44 AM   #23
kappax
Registered User
 
Join Date: Oct 2002
Posts: 56
Default

Quote:
Originally posted by Chalnoth
Um. I'm getting swapping with cache still in use (~100MB or so of cache in use). I have 256MB of RAM.



Right. What I'm apparently seeing is that the cache isn't being cleared out quickly enough, and a little bit is being written to swap to clear out the necessary memory (Generally 200k-500k at a time).

While this could be an optimization issue (whatever is being written to swap is most probably not something that's been used recently), I'd rather that the cache is cleared instead of writing things to swap.



Athlon XP 2000+
nForce2
GeForce4 Ti 4200

Anyway, even if the IDE settings were bad, they should not have ever affected in-game performance. There shouldn't be anything writing to the HD while I'm playing.

I haven't checked the FPS, but I'll have to get back to you on that (in windows atm).

It is conceivable that it's the sound drivers. I'll have to look into that some more.



Redhat 7.3
ok yes it could be IDE, UT2003 is a large game and has many textures, and can need to get data from the HD at any time.

2

you can keep the 7.3, but upgrade to the 2.4.19 kernel with preimpt and lolate

as far as i know, there is only 2 cases someting goes to swap.

1. you are out of ram and need to use vertual ram.

2. someting sits in the ram for a long time without being accessed, then is put on swap because it is not needed.

Last edited by kappax; 11-25-02 at 01:53 AM.
kappax is offline   Reply With Quote
Old 11-25-02, 02:29 AM   #24
Chalnoth
Registered User
 
Join Date: Jul 2002
Posts: 1,293
Default

Yes, I just recently upgraded the kernel, and that seems to have helped. I'm back to using the Radeon 9700 for now, though, so it may be a little while before I get back to looking at this stuff (R9700 doesn't want to work in Linux due to lack of agpgart for nForce2).
Chalnoth is offline   Reply With Quote
Reply


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


Similar Threads
Thread Thread Starter Forum Replies Last Post
xorg memory leak? amast NVIDIA FreeBSD 0 09-01-12 08:36 PM
Memory leak in KDE plasma-desktop process with Nvidia driver shmerl NVIDIA Linux 0 08-07-12 10:27 AM
DOE Doles Out Cash to AMD, Whamcloud for Exascale Research News Archived News Items 0 07-12-12 07:50 PM
Xorg Memory Leak AndrewM NVIDIA Linux 1 07-02-12 11:30 AM
Measuring card memory usage peter_ga NVIDIA Linux 0 05-24-12 08:07 PM

All times are GMT -5. The time now is 06:01 PM.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Copyright 1998 - 2014, nV News.