Memory Limit with MetaTrader Terminal.

 

Hello People

Today I was running some intensive calculation with my EA. The calculation uses lots of arrays and loops and therefore the calculation uses up quite a lot of memory. I understand this. However, the odd thing but interesting thing is this:

I have 8 GB of Physical memory plus virtual memory can be used from 4 GB to 12 GB which I believe quite sufficient to complete the whole calculation with my EA. However, the calculation stopped in the middle (more precisely crashed MetaTrader terminal). 

So I checked from task manager, Meta Trader was using nearly 1.3 GB of Memory. At this time, I was still having nearly 4 GB of free Physical memory as well as quite a lot of free virtual memory plus my CPU was not even used more 25%.

I still think the memory is the problem to stop the calculation as when I run the calculation with small loop, then I was able to complete the whole calculation. 

I am quite curious if there is a way I can make the calculation keep going until I can make use of 80% to 90% of my Physical Memory or virtual memory. or I am curious if MetaTrader 5 terminal designed such a way to stop the terminal if the memory usage goes beyond what it suppose to be?

It will be really appreciated if you can share your wisdom.

Kind regards.

 

Have you tried setting the process priority higher from Task Manager? I have no other ideas at the moment.

 
Candles:

Have you tried setting the process priority higher from Task Manager? I have no other ideas at the moment.

I am giving a go now with your idea. I will let you know. :)
 
Candles:

Have you tried setting the process priority higher from Task Manager? I have no other ideas at the moment.

Tried but again the calculation stopped. At this time, Terminal was using nearly 1 GB of memory and I was having around 4 GB of free Physical memory and CPU usage was only aboud 20%.

So that idea does not work.

Kind regards.  

 
I'm actually having a similar problem with a few EAs since the last update. Sometimes it works fine, other times MT freezes and locks the whole PC so I have to do a hard restart. Very odd as my memory usage is below 40% and CPU under 10%.....?
 
Filter:
I'm actually having a similar problem with a few EAs since the last update. Sometimes it works fine, other times MT freezes and locks the whole PC so I have to do a hard restart. Very odd as my memory usage is below 40% and CPU under 10%.....?
Good to know you are experiencing the similar problem. It will be good if someone knows about the architecture of metatrader can share his advice here. :)
 
FinanceEngineer:

Today I was running some intensive calculation with my EA. The calculation uses lots of arrays and loops and therefore the calculation uses up quite a lot of memory. I understand this. However, the odd thing but interesting thing is this:

If it crash it surely reach a limit it is unable to manage, for example a limit in the number or arrays, and not just an out of memory problem.

I can only suggest to log these numbers to spot the point where it stops. No need to save every output, just to rewrite the current status of the expert.

 
FinanceEngineer:

Tried but again the calculation stopped. At this time, Terminal was using nearly 1 GB of memory and I was having around 4 GB of free Physical memory and CPU usage was only aboud 20%.

So that idea does not work.

Kind regards.  

Are you using 64 bits or 32 bits version of MT5 ?

Is there any message in the Journal log ?

Anyway, I suggest you to write to ServiceDesk, as in all cases MT5 should not crash.

 
angevoyageur:

Are you using 64 bits or 32 bits version of MT5 ?

Is there any message in the Journal log ?

Anyway, I suggest you to write to ServiceDesk, as in all cases MT5 should not crash.

For me, I'm running 64bit and there's nothing in the Journal Log. And sometimes as MT freezes within a few seconds of opening it, there's nothing written to the log file on disk either, just a zero kb file. I'm sending info to Service Desk now
 
Filter:
For me, I'm running 64bit and there's nothing in the Journal Log. And sometimes as MT freezes within a few seconds of opening it, there's nothing written to the log file on disk either, just a zero kb file. I'm sending info to Service Desk now
Thank you. Please report any relevant information here, so maybe we can learn something.
 
angevoyageur:
Thank you. Please report any relevant information here, so maybe we can learn something.
Will do
Reason: