Where is my memory going?

Soldato
Joined
18 Jan 2005
Posts
4,171
Location
Northants
I'm having massive problems with bf2 paging, and i have 2gb of memory and i know it runs smoothly with 2gb and it doesn't run smoothly with 1gb which is why i upgraded, so i think something is wrong.

The memory usage of bf2 is reported at 240mb, and added to the rest of the processes does not add up to the 1940mb of used memory taskmanager reports...

memoryaf4.png


Look at that ridiculous pagefile...
Any ideas?

Thanks
 
No, should i?

Folding hardly uses anything thankfully.

I wonder if there is a utility that could find whats stealing my memory...
 
Craig321 said:
Yup, you should do virus scans and stuff :)

Ad-Aware
13 tracking cookies removed. Nothing capable of eating 2gb of memory methinks.
A-Squared
Picked up 8 items that were all registry keys made by vnc, completely harmless. Not impressed. Also found 3 medium risk items and one low risk, mostly registry keys apparently.
Spysweeper
Found nothing.
Spybot S&D
Decided that me disabling windows security centre notifications is a threat. Found a few tracking cookies.
Windows Defender
Needs a legal copy of windows iirc.

So its clean, what shall i do next?
 
rpstewart said:
In Task Manager, when on the Processes tab go to the view menu and pick "Select Columns", you can then add a page file usage column to the processes list and see what is actually chewing up the page file.
I don't see an column called pagefile but there is one called virtual memory size, is that it?
try using a program called HiJack This... really good... run it and let me know what it brings back
Thanks, i'll give that a try.
Does it only thrash while playing BF2?
Yes, only because bf2 uses a massive amount of memory.

The problem is not the pagefile, its the fact that the memory being used by the running processes including bf2 does not add up to even half my available memory, yet all my memory is in use and as a result bf2 only gets 240mb and so has to page because something else seems to be stealing half my memory and not showing up in the processes list.

Suppose it could be your running a program with a memory leak that isn't freeing it up properly, would try running BF2 with absolutely everything disabled.
Bf2 has had memory leaks before and they say they are 'aware of the problems users are having with patch 1.3' i.e the game still doesn't work at least 6 months after release, so it could well be that the game has a memory leak. However if it did, wouldn't it show in task manager, wouldn't it display bf2 using a massive amount of memory?

Thanks for all your help everyone.
 
Stelly said:
try using a program called HiJack This... really good... run it and let me know what it brings back

Stelly
Ok i've run it, what am i looking for? Do i need to run it while running bf2? Should i send you the logfile?

Thanks

I'm going to run bf2 now and take a look at pagefile usage, and then i'm going to try moving the pagefile and changing it and see if that has any effect, although i think this is a memory problem rather than a pagefile problem.
 
UKTopGun said:
You say folding isnt using much but I see it as it using up a total of 97 CPU - surely thats a lot isnt it?

Sorry if I'm wrong / reading it wrong.
Thats because bf2 is minimized.
When maximized bf2 uses one core which is 50% and folding will only run on whats left over, which is the other core.
Folding only uses the cpu when nothing else is using it, and when bf2 is minimized it is not using it so folding uses it.
It is being run on the other core
No, it runs on both except when they are in use by something else. ;)


I have found my problem. Bf2 runs fine in single player, and in multiplayer using 900mb of memory and 900mb of pagefile and runs smoothly until about halfway through the 2nd round. At this point its memory usage suddenly drops to around 200mb.
The reason for this is windows pops up a message saying 'windows has detected that your pagefile is too small and is increasing it. During this time some pagefile requests will be denied' or something to that effect.
So this is screwing up bf2.

I'm going to mess around with my pagefile settings and see if this fixes it.
 
Ok, changing my pagefile to system managed does exactly the same thing but doesn't pop up a message.

After playing the game for a time using 900mb of memory it will drop to and become limited to 200mb and is forced to page instead. I have no idea why windows adjusting the pagefile size should limit it to 200mb.

Any other things i can try?
 
squiffy said:
Fresh install :p
Of what, bf2 or xp?
I wouldn't be at all supprised if its another bf2 bug so i might contact ea support again and see what they say.
Try downloading XP-antispy, tick the 'clear pagefile at shutdown' box, reboot and see what happens.

Long shot and it prolly wont work but its worth a try if nothing else.
I might give that a try. Rebooting seems to 'reset' it, and it doesn't come back until i play the game for a while.
 
I think i had it set to 10gb originally but i'll have another try.
Why its having to page so much with 2gb of ram remains to be seen, as its only using around 900mb and i'm sure there is more available than that.
 
Cyber-Mav said:
do what i did and get 4 gigs of ram. you will get no problems with it. ;)
I don't need 4gb of ram. Its not using what i've got, thats the point.
Nothing needs 4gb of ram so whats the point, 2gb of it would sit empty. Programs will always page regardless of the amount of ram installed.
Performance of my system would be identical with 4gb of ram or 2gb.

Its particularly wasted in your system as you have a mid range graphics card which couldn't run games at the sort of detail levels that require 2gb, let alone 4. If you had got 2gb and spent the extra money on a better graphics card i guarantee your system would perform far better than getting a lesser graphics card and an extra 2gb of ram.
 
Last edited:
I think the problem is bf2 isn't freeing up memory when its finished with it. Thats the only logical explanation i can think of. Everything behaves as if 1.6gb of my memory is in use by something else and that only happens after bf2 has been using most of that memory.
Can anyone explain to me what a memory leak is, is this one?
 
Tetras said:
Couple of google definitions for you :)
# A programming term describing the losing of memory. This happens when the program allocates some memory but fails to return it to the system. Excessive memory leaks can lead to program failure after a sufficiently long period of time.

# Memory leaks are often thought of as failures to release unused memory by a computer program. Strictly speaking, it is just unneccesary memory consumption. A memory leak occurs when the program loses the ability to free the memory. A memory leak diminishes the performance of the computer, as it becomes unable to use all its available memory.
http://en.wikipedia.org/wiki/Memory_leak

Online games are particularly suspectible, a lot of mmos have that problem.
Bingo. There you have it. I'm sure thats whats going on. I'll have to contact ea and find out why, and hope the 1.4 patch fixes it. Thanks for the definitions.
Did you get round to trying the larger fixed swapfile btw? And I'm guessing you've tried turning folding off? Drive/swapfile fragmented?
Tried setting a 3gb pagefile, yes, i have tried a different drive but i'll try again as i can't remember if i was having this issue with the pagefile on the other drive. Haven't tried turning folding off as i see no reason to suspect it.
Really i think this is a memory leak in bf2, perhaps caused by something else in combination with bf2 but i think the pagefile issue is only a side effect.
 
Tetras said:
It is at least one of the reasons why people refer to BF2 as still being in beta, memory leaks tend to be sloppy or unfinished code imo.
Absolutely. It has had a memory leak in one of the server versions that caused constant server crashes and it took weeks to fix.
Its ridiculous that paying customers are used as beta testers, and they keep bringing out new addon packs to try and get more money out of us while the game remains unfinished.
 
SameSuspect said:
ridiculous isnt it. Well 2142 is in free beta at the minute, hopefully it wont be as dodgy when its released. hopefully
Not a chance, they haven't been working on that for very long at all, there is no way its near finished and i doubt it will be finished when its released.
Why can't they get bf2 working first before they make another one and loads of addon packs.
 
Install it and see. As i'm not having that specific problem i can't say. They never reveal what they have actually fixed, presumably because there is so much and also because many of the problems manifest themselves in different ways depending on the system.

I still have to install everything in safemode otherwise it won't even start up or will crash while loading.
 
Its still happening with patch 1.4. I might have known. Back to my ole friends at ea support then.
The pillocks who coded this need to be hosed down with their own excrement.

BugFest 2.
 
Back
Top Bottom