EA's on VPS server not working/server cpu at 0%

 
Hi, I've recently migrated a few EA's onto the my MQL5 server but they haven't opned any trades, I had thought that I just hadn't waited long enough, but when I looked on the server details the CPU is running at 0%. The Disk and memory seem to be running at a normal level and the EA's worked fine on the strategy tester so I'm not really sure what to do. Hope someone can help! Cheers in advance x  
 
henrygeer:
Hi, I've recently migrated a few EA's onto the my MQL5 server but they haven't opned any trades, I had thought that I just hadn't waited long enough, but when I looked on the server details the CPU is running at 0%. The Disk and memory seem to be running at a normal level and the EA's worked fine on the strategy tester so I'm not really sure what to do. Hope someone can help! Cheers in advance x

Don't post picture(s) with your name and account number on it.

 
If 4 charts with 4 EAs attached were sucessfully migrated (according to your log) so it works.
If it does not work so it is related to your EA.

Because this VPS is the "copy of your Metatrader in cloud" - means: this is the other your Metatrader by located in cloud. And if EAs works on your home Metatrader so it will work on MQL5 VPS. And if any error/issue - you can see it on the logs/journal.
Virtual hosting for MetaTrader 5
Virtual hosting for MetaTrader 5
  • www.mql5.com
Virtual hosting for MetaTrader 4/5 is the best VPS solution for Forex. It is cheap, it requires no configuration and it features minimum delays to the server. For only 15 USD per month, you obtain a virtual platform that works around the clock, saves your profit and pays off. Create a remote copy of the application directly from the...
 
henrygeer:
Hi, I've recently migrated a few EA's onto the my MQL5 server but they haven't opned any trades, I had thought that I just hadn't waited long enough, but when I looked on the server details the CPU is running at 0%. The Disk and memory seem to be running at a normal level and the EA's worked fine on the strategy tester so I'm not really sure what to do. Hope someone can help! Cheers in advance x

Your EAs are loaded succesfully and everything seems to run normal.

The answer is maybe at the fact you've only migrated your EAs today and from their name I can guess that they trade on the daily timeframe, so give them some time, maybe your trading criteria are not met.

A piece of advice, go to your chart settings and put your max bars on chart to about 500-1000, more than that are useless and they tend to slow things down.
 
Eleni Anna Branou:

Your EAs are loaded succesfully and everything seems to run normal.

The answer is maybe at the fact you've only migrated your EAs today and from their name I can guess that they trade on the daily timeframe, so give them some time, maybe your trading criteria are not met.

A piece of advice, go to your chart settings and put your max bars on chart to about 500-1000, more than that are useless and they tend to slow things down.

Hi, I've had it running on the VPS for about a week and it still hasn't opened any trades but I've had the same EA running on the same currency pair on my demo account while having MT4 open on my laptop this afternoon and it has just opened a trade so it the EA works fine it just doesn't work on the VPS/the VPS doesn't work. Do you know why this might be? or what I can do to fix this?

 
Sergey Golubev:
If 4 charts with 4 EAs attached were sucessfully migrated (according to your log) so it works.
If it does not work so it is related to your EA.

Because this VPS is the "copy of your Metatrader in cloud" - means: this is the other your Metatrader by located in cloud. And if EAs works on your home Metatrader so it will work on MQL5 VPS. And if any error/issue - you can see it on the logs/journal.
Hi, I've had it running on the VPS for about a week and it still hasn't opened any trades but I've had the same EA running on the same currency pair on my demo account while having MT4 open on my laptop this afternoon and it has just opened a trade so it the EA works fine it just doesn't work on the VPS/the VPS doesn't work. Do you know why this might be? or what I can do to fix this?
 
henrygeer:
Hi, I've had it running on the VPS for about a week and it still hasn't opened any trades but I've had the same EA running on the same currency pair on my demo account while having MT4 open on my laptop this afternoon and it has just opened a trade so it the EA works fine it just doesn't work on the VPS/the VPS doesn't work. Do you know why this might be? or what I can do to fix this?

If you sucessfully migrated so EA should work.
And you can migrate once again (for example).

  • EA will not work if the EA is using (or trying to use) dll.
  • Besides, it is based on how EA was coded. For example, iTrend indicator from Brainwashing system is showing different results/values for different brokers. And some EAs (most of the EAs) may perform differently for different brokers/accounts (because the data/quotes are slightly dofferent). 
  • Besides, it may be related to the build of Metatrader: you are having one build at home, and your MQL5 VPS Metatrader is having the other metatrader build, and your EA does not work with that MQL5 VPS Metatrader build (there are many examples/threads here related to the builds).

MQL5 VPS is the other Metatrader located in cloud, and this Metatrader does not care about what you attached to the chart ... EA works or EA does not work ... and it is not related to MQL5 VPS sorry.

 
henrygeer:
Hi, I've had it running on the VPS for about a week and it still hasn't opened any trades but I've had the same EA running on the same currency pair on my demo account while having MT4 open on my laptop this afternoon and it has just opened a trade so it the EA works fine it just doesn't work on the VPS/the VPS doesn't work. Do you know why this might be? or what I can do to fix this?

There are many reasons why the EA opened a trade on your demo account and didn't on the MQL5 VPS, make sure that you have the same settings on both versions and that your EA doesn't require DLL as Sergey mentioned.

We only see what you are telling us, we don't see your settings and your EA's trading criteria, so we can't see if something is wrong at your end.

 
Eleni Anna Branou:

There are many reasons why the EA opened a trade on your demo account and didn't on the MQL5 VPS, make sure that you have the same settings on both versions and that your EA doesn't require DLL as Sergey mentioned.

We only see what you are telling us, we don't see your settings and your EA's trading criteria, so we can't see if something is wrong at your end.

//+------------------------------------------------------------------+
//|                                                       Daily1.mq4 |
//|                        Copyright 2020, MetaQuotes Software Corp. |
//|                                             https://www.mql5.com |
//+------------------------------------------------------------------+
#property copyright "Copyright 2020, MetaQuotes Software Corp."
#property link      "https://www.mql5.com"
#property version   "1.00"
#property strict

extern int TakeProfit = 100;
extern int StopLoss = 20;
extern bool UseTrailingStop = true;
extern int WhenToTrail = 40;
extern int TrailAmount = 40;
extern double LotSize = 0.10;
extern int MagicNumber = 1234;
double Pips;






//+------------------------------------------------------------------+
//| Expert initialization function                                   |
//+------------------------------------------------------------------+
int OnInit()
  {
//---
   double ticksize = MarketInfo(Symbol(),MODE_TICKSIZE);
   if(ticksize == 0.00001 || ticksize == 0.001)
   Pips = ticksize*10;
   else Pips = ticksize;
//---
   return(INIT_SUCCEEDED);
  }
//+------------------------------------------------------------------+
//| Expert deinitialization function                                 |
//+------------------------------------------------------------------+
void OnDeinit(const int reason)
  {
//---
   
  }
//+------------------------------------------------------------------+
//| Expert tick function                                             |
//+------------------------------------------------------------------+
void OnTick()
  {
//---

   if(Close[0]>Open[1])
   if(OrdersTotal()==0)
   OrderSend(Symbol(),OP_BUY,LotSize,Ask,3,Ask-(StopLoss*Pips),Ask+(TakeProfit*Pips),NULL,MagicNumber,0,Green);  

   if(Close[0]<Open[1])
   if(OrdersTotal()==0) 
   OrderSend(Symbol(),OP_SELL,LotSize,Bid,3,Bid+(StopLoss*Pips),Bid-(TakeProfit*Pips),NULL,MagicNumber,0,Red);
  
   for(int b=OrdersTotal()-1;b>=0;b--) 
   if(OrderSelect(b,SELECT_BY_POS,MODE_TRADES))  
   if(OrderMagicNumber()==MagicNumber) 
   if(OrderSymbol()==Symbol())
   if(OrderType()==OP_BUY)
   if(Bid-OrderOpenPrice()>WhenToTrail*Pips)
   if(OrderStopLoss()<Bid-TrailAmount*Pips)
   OrderModify(OrderTicket(),OrderOpenPrice(),Bid-(TrailAmount*Pips),OrderTakeProfit(),0,CLR_NONE);
   
   for(int s=OrdersTotal()-1;s>=0;s--)
   if(OrderSelect(s,SELECT_BY_POS,MODE_TRADES))
   if(OrderMagicNumber()== MagicNumber)
   if(OrderSymbol()==Symbol())
   if(OrderType()==OP_SELL)
   if(OrderOpenPrice()-Ask>WhenToTrail*Pips)
   if(OrderStopLoss()>Ask+TrailAmount*Pips)
   OrderModify(OrderTicket(),OrderOpenPrice(),Ask+(TrailAmount*Pips),OrderTakeProfit(),0,CLR_NONE);   
  
   }



//+------------------------------------------------------------------+

This is my EA I am trying to run. I have allowed live trading, got smiley faces on the charts, haven't got any error messages on the experts section or journal. Running the EA on 6 currency pairs means that it should take on average 2.88 trades per day and it has opened none this week. Hope you can help!

Thank you in advance

 
henrygeer:

This is my EA I am trying to run. I have allowed live trading, got smiley faces on the charts, haven't got any error messages on the experts section or journal. Running the EA on 6 currency pairs means that it should take on average 2.88 trades per day and it has opened none this week. Hope you can help!

Thank you in advance

Your EA is loaded and initialized succesfully on the VPS, I don't know about the coding part, maybe a coder can help.

 
Eleni Anna Branou:

Your EA is loaded and initialized succesfully on the VPS, I don't know about the coding part, maybe a coder can help.

okay no worries! :)
Reason: