first_MCITP
asked on
Out of Memory Error
While I am running a certain application, it hangs and an out of memory error begin appearing. I tried a lot then i figured that the used memory is just about 500 MB when the out of memory error appeared. My cash is 2 GB and I have 4 GB RAM
anybody has a solution for that?
anybody has a solution for that?
Quite likely it is a RAM(s) problem as already described, but you may like to have a look at the 'Resolution' in this MS article >>
"Out of Memory" error message appears when you have a large number of programs running:
http://support.microsoft.com/kb/126962
"Out of Memory" error message appears when you have a large number of programs running:
http://support.microsoft.com/kb/126962
ASKER
I already did that. The problem is not a deffective RAM. I noticed that whenver a process loads to the memory about 3000 KB it will hang and raise the out of memory error, while since I have enough memory i can run another process safely??
Windows memory is not one big block, it is compartmented into smaller "heaps" that hold specific kinds of resources. Some of these heaps by default are very small (at least in 32bit XP), and when they are full, you get an out-of-memory error, no matter how much free RAM is left.
If it is only this one application, then it may be either leaking or very resource intensive.
Also, some runtime environments create their own heap, like the Java VM does for all java programmes running within it. That heap, by default, is still only 1 Mb and may extend to 16 mb. If this is a Java application and you need more memory for it, you have to start Java with specific parameters, as explained here:
http://viralpatel.net/blogs/2009/01/jvm-java-increase-heap-size-setting-heap-size-jvm-heap.html
Here is guide for increasing the desktop heap:
http://www.techarp.com/showarticle.aspx?artno=238
If it is only this one application, then it may be either leaking or very resource intensive.
Also, some runtime environments create their own heap, like the Java VM does for all java programmes running within it. That heap, by default, is still only 1 Mb and may extend to 16 mb. If this is a Java application and you need more memory for it, you have to start Java with specific parameters, as explained here:
http://viralpatel.net/blogs/2009/01/jvm-java-increase-heap-size-setting-heap-size-jvm-heap.html
Here is guide for increasing the desktop heap:
http://www.techarp.com/showarticle.aspx?artno=238
ps:
What does your event log say about the error?
What does your event log say about the error?
What is the memory configuration?
Slots used?
Size of each stick?
Slots used?
Size of each stick?
ASKER
thank you torimar;
I am using a vb 6.0 application.
I tried the link you gave but it still the same
in event viewr it shows Application Pop up information of event id: 26
description:
"pplication Error : The application failed to initialize properly (0xc0000142). Click on OK to terminate the application. "
I am using a vb 6.0 application.
I tried the link you gave but it still the same
in event viewr it shows Application Pop up information of event id: 26
description:
"pplication Error : The application failed to initialize properly (0xc0000142). Click on OK to terminate the application. "
check out this page and see if this helps ... http://www.vbforums.com/archive/index.php/t-299967.html
ASKER
I tried all the previous but still the same
any clue?
any clue?
ASKER
I am using 8 GB RAM, 2+2+4
Have you tried removing all RAM except the 4 GB on it's own, or initially one of the 2's on it's own? If it works without the error, we can go from there ...
ASKER
Yes I tried removing the RAM. Also Itried the same application on different servers and it showed the same error
Ok, reason i asked were these two threads >
How much ram can I install in a motherboard under XP:
https://www.experts-exchange.com/questions/23952232/How-much-ram-can-I-install-in-a-motherboard-under-Windows-XP.html?cid=238&anchorAnswerId=23086997#a23086997
"Max memory":
https://www.experts-exchange.com/OS/Microsoft_Operating_Systems/Windows/XP/Q__22510635.html
How much ram can I install in a motherboard under XP:
https://www.experts-exchange.com/questions/23952232/How-much-ram-can-I-install-in-a-motherboard-under-Windows-XP.html?cid=238&anchorAnswerId=23086997#a23086997
"Max memory":
https://www.experts-exchange.com/OS/Microsoft_Operating_Systems/Windows/XP/Q__22510635.html
ASKER
I am aware of the 32 bit and 64 bit Os, that's why i tested the application on win server 2003 64 bit of 10 GB but still the same.
I created an application that loads the emory and whenver it loads about 2.8 GB to memory it hangs, but i still can run another instant of that application but at this time will not load that amount. and running another instant will sure load less amount and so on
It's something confusing cause i tried a lot of solutions but still i can't find the appropriate solution. I think it's something preventing a process from loading memory with data larger than 3 Gb or something like that.
I created an application that loads the emory and whenver it loads about 2.8 GB to memory it hangs, but i still can run another instant of that application but at this time will not load that amount. and running another instant will sure load less amount and so on
It's something confusing cause i tried a lot of solutions but still i can't find the appropriate solution. I think it's something preventing a process from loading memory with data larger than 3 Gb or something like that.
ASKER
the issue of the 4 GB, is appearing whenver i try to load more than 4 GB to memory which is not addressable by 32 bit OS. But still when i try to load more than 3 GB using one process this process will hang.
I think think is the major issue and i am focusing on a solution if i can allow a certain process to access more than 3GB of memory
I think think is the major issue and i am focusing on a solution if i can allow a certain process to access more than 3GB of memory
So maybe worthwhile looking at the reasoning behind the /3GB switch used in the BOOT.INI file, from the Q__22510635.html thread above.
first_MCITP,
don't you think you should have told us right from the start what you were doing?
Please refer to your original question: there is no mention of your application being designed for testing memory, and there is also no mentioning of a ~3GB memory limit: you were originally talking about 500 mb.
If you have the "/3GB" switch working on your server (like Jonvee pointed out as a possibility), then this will mean that user mode processes are allowed a maximum of 3GB address space. Windows only gets 1 GB of address space, and is impeded in its multi-tasking functionality.
This would explain perfectly what you are experiencing.
And I guess you would have received this explanation in the first comment, had you told us all we need to know.
For example:
I checked through all the known event ID 26 errors; there is only one that deals with memory. But it refers to running out of virtual memory - which did not seem to fit the scenario as you originally described it. So I refrained from following that clue any further. But now, knowing that you actually try to load up on data in memory until you hit a limit, this will fit again.
don't you think you should have told us right from the start what you were doing?
Please refer to your original question: there is no mention of your application being designed for testing memory, and there is also no mentioning of a ~3GB memory limit: you were originally talking about 500 mb.
If you have the "/3GB" switch working on your server (like Jonvee pointed out as a possibility), then this will mean that user mode processes are allowed a maximum of 3GB address space. Windows only gets 1 GB of address space, and is impeded in its multi-tasking functionality.
This would explain perfectly what you are experiencing.
And I guess you would have received this explanation in the first comment, had you told us all we need to know.
For example:
I checked through all the known event ID 26 errors; there is only one that deals with memory. But it refers to running out of virtual memory - which did not seem to fit the scenario as you originally described it. So I refrained from following that clue any further. But now, knowing that you actually try to load up on data in memory until you hit a limit, this will fit again.
ASKER
OOPs I was mistaken it is allocating 2 GB for one process.
Dear Jonvee;
the /3G switch is to allow window use 1 GB and user use 3 GB but I am talking here about a process which will not use more than 2 Gb although i can run another process to consume more memory until i reach the 3+1 GB.
Hope you got my point
Dear Jonvee;
the /3G switch is to allow window use 1 GB and user use 3 GB but I am talking here about a process which will not use more than 2 Gb although i can run another process to consume more memory until i reach the 3+1 GB.
Hope you got my point
ASKER
Dear Torimar;
The things related to memory loader application and the other is coming after. First I was facing this error then i was trying to figure why and whenever I conclude to a posting it. and due to the /3G yes its configured but as I replied to Jonvee, if the 3 Gb is totally consumed i will not be able to run any other instance.
For your info also i tried my memory loader application to a 64 bit server and the result still the same.
The things related to memory loader application and the other is coming after. First I was facing this error then i was trying to figure why and whenever I conclude to a posting it. and due to the /3G yes its configured but as I replied to Jonvee, if the 3 Gb is totally consumed i will not be able to run any other instance.
For your info also i tried my memory loader application to a 64 bit server and the result still the same.
ASKER
Dear Guys;
I found the cause of the problem.
I was logging remotely using terminal server that's why windows why trying allocate few resources to me, I changed the desktop heap and its working fine now.
Thank you
I found the cause of the problem.
I was logging remotely using terminal server that's why windows why trying allocate few resources to me, I changed the desktop heap and its working fine now.
Thank you
Dear first_MCITP,
sorry for interfering with the proposed closing procedure, but I have to comment on it.
In your proposed solution (ID:24438616) you say:
"... windows why trying allocate few resources to me, I changed the desktop heap and its working fine now."
If you review my first comment ID:24421344, then you will see that:
1. - I was the one to introduce the concept of "heaps" into this thread;
2. - I suggested that a wrong heap setting could very well explain the problem you encountered;
3. - I suggested that the application you were having a problem with was perhaps "very resource intensive" - which would account for a heap overflow;
4. - I finally gave you the link to a site that a) describes the 'desktop heap', and b) explains how to change it.
So it appears like all clues to the final solution of the problem are already there in my comment. To me, this seems to be worth more than an assist with only a fifth of the point pool.
I file this objection in order to have a moderator review the thread and verify whether my judgment is correct or not.
sorry for interfering with the proposed closing procedure, but I have to comment on it.
In your proposed solution (ID:24438616) you say:
"... windows why trying allocate few resources to me, I changed the desktop heap and its working fine now."
If you review my first comment ID:24421344, then you will see that:
1. - I was the one to introduce the concept of "heaps" into this thread;
2. - I suggested that a wrong heap setting could very well explain the problem you encountered;
3. - I suggested that the application you were having a problem with was perhaps "very resource intensive" - which would account for a heap overflow;
4. - I finally gave you the link to a site that a) describes the 'desktop heap', and b) explains how to change it.
So it appears like all clues to the final solution of the problem are already there in my comment. To me, this seems to be worth more than an assist with only a fifth of the point pool.
I file this objection in order to have a moderator review the thread and verify whether my judgment is correct or not.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Dear Torimar;
Yes you are right, you was very helpful in finding the solution.
Dear support;
What is needed to be done now?
Yes you are right, you was very helpful in finding the solution.
Dear support;
What is needed to be done now?
Thank you very much, first_MCITP, for returning to this thread and clearing the issue.
Since you accepted a solution, the question way correctly closed, and nothing else needs to be done.
Since you accepted a solution, the question way correctly closed, and nothing else needs to be done.
You can also download and run memtest86. Let this run through completely several times to thoroughly test the Ram.
http://www.memtest.org/