So I'm going to start automated trading -- Help with server

Having a hard time remembering how I traded coupled with my lack of time (and patience) to sit at the screen all day and wait for events to happen, only to give up go to bed, and wake up realizing that they happened while I was sleeping.

My first order of business is getting a new broker, I’ve opened another account with FXOpen they seem to have good spreads and from what I’ve read good execution, they also offer MT4, unlike Oanda.

My Next order of business is getting MT4 to trade like I trade, and to do what I mean not what I say… Hopefully I’ll have some hair left before the end of this. :wink:

My challenge right now is, I have not used Windows in over 5 years at this point. I use Linux, but to ensure a sooth operation I would prefer to run this on a Windows machine. I got a server running Windows 2008 right now, I could also have it run Windows 2003… The host has a better uptime, internet, etc then I could have, and if you add all the costs up they are cheaper then me having my own box with required accessories.

My problem… I’m loosing hair coding, and I’m loosing hair trying to get MT4 to run persistently. I haven’t the slightest idea how to use Windows, espically not for such important tasks. I can RDP into the server but I’m lost at how to get MT4 to run when I’m not logged in. I have tried to run it as a service as somebody suggested and I found a program to act as a wrapper for it, but it keeps crashing.

Anybody know how to run MT4 persistantly? If your suggestion is to go with one of those companies that specialize in hosting MT4, I have resevations about that. There are times when I could use a Windows box to run a program or two, and I would want to be able to do that. I also want to be able run as many things as I feel like. My host doesn’t charge upfront, and I’ve used them for awhile now and am quite content. Heck, they charge by the hour! $0.08 an hour rocks. Too bad Windows needs such high specs, my Linux servers start at only $0.015/hr =)

I may use Linux if I cant resolve this stupid Windows issue, and because I dont care about data integrety I’ll start up a new box and allow access to it, if somebody can show me the light. Before you get any ideas, said server would be deleted upon being shown how to do it :wink:

I’m a paranoid security freak… thats why I like Linux :wink:

I am not much help. The obvious solution is a FX mt4 server some brokers offer that service free or very cheap.

I am interested in your situation as I am looking at FXCM’s strategy trader I have not found anyone that offers a server with that platform installed. The word from FXCM is its in the works at a cost or with balance restrictions.
In the meantime I am planing to get an old low spec box with xp and run it myself from home. I found a few good free remote access apps and services online and I know of and have used some good opensource ones as well. I have good power reliability and my internet is up almost all the time at my house. $60 a month running 24/7 for your existing server is in the ballpark with the cheaper windows servers I have looked at. At that price I decided that it made more sense for me to set up my own at this point. Down the road if I get a trading system thats working well I will look at having the bot hosted. I think an off site server will have better reliability then I can manage at my house.

EDIT… I am a big Puppy Linux fan and user:D. I found that for trading nothing beats a clean XP pro install.

Oh don’t get me wrong, I’m not going to start hosting it today, but I do need to solve this problem otherwise, why write an EA? :wink:

Metatrader is always a bit on the tweaky side in wine… I don’t trust it under heavy load…

I am not sure if you received an answer for this I too prefer linux, although I use Windows, I have a Linux hosting server and wanted to setup MT4 on my hosting server, which is a dedicated server…

I soon just opened up a VPS with a windows box. I have spent the last month trying to optimize this Windows Server 2003 to run the MT4 platform effectively… .meaning with low resources so that the speed of trading is quick using EA’s (If I could find an easy way to setup my Linux Host server (Hostgator) with MT4 Platforms I would do that)… I have not been able to find an easy step by step guide to do so…

So… My first resource can be found at this link CK’s MT4 VPS setup manual is an excellent starting point.

www(dot)ckowyong(dot)com/blog/members/vps_guide_for_mt4_v1.1.pdf

  1. The first part of the manual works well in getting the VPS to automatically login as an Administrator after outages or reboots.

  2. I had difficultly getting the second part of his manual to work, namely getting the MT4 Programs to startup when placed into the StartUp folder, Using his recommended start.cmd batch program. They would only startup after I loggedin…

To solve that issue what I did is put each program into the “startup” folder and alter the startup properties of each of the programs in that folder by adjusting the Target Shortcut path [B]“C:\Program Files (x86)\VantageFX Trader Demo 2 erminal.exe” /t 30 [/B] I have 4 MT4 platforms loading up and you need to stagger the restart of each platform by 30 seconds so the Switch /t at the end is increased my 30 for each platform. So I have a sequential reload of the platforms after reboot. The “Startup” Folder must be the “Administrator” “Startup” folder. /t is time followed by a seconds so it is written after the the shortcut [space]/t[space]time in seconds… ie. “C:\Program Files (x86)\VantageFX Trader Demo 2 erminal.exe” /t 30

The reason I used this method is because when I tried CK’s the start.cmd would only load up when I logged in… not what I wanted… the above is now working automatically…

  1. My VPS reboots automatically after outages…
  2. My MT4 Platforms automatically restart sequentially every 30 seconds after reboot.

I also have scheduled a Daily restart for the VPS using CK’s VPS Setup suggestion. and everything is now working well…

Except for one thing… I have noticed that "Instead of 4 terminal.exe’s showing up in the Taskmanager there are 8 instances of terminal.exe… using resources and only four instances are visible on the Desktop…

so I am getting a double load of the MT4 programs and only able to see one of the programs. I now have to manually delete the extra terminal.exe for each of the non visible terminal.exe’s showing up in the Taskmanager.

I have concluded that these extra programs could in reality be trading without me knowing it, not a good situation.

That is the reason I am now on this site as I am trying to find a work around for this last little problem… Plus I hope the information above will be useful for others trying to automate their MT4 VPS setups.

One last point in order to stream line each of the MT4 programs to use less resources… namely RAM I have changed the Chart Display for Bars to 20000 for each of the platforms and it has decreased the RAM usage by 50%.

This will provide quicker speed in trading…

PLEASE IF ANYONE… can provide an answer to the double terminal.exe’s loading up… one visible on the desktop and one not visible on the VPS desktop I would be a very happy trader

Hello @KJB777,

This is my first forum post/reply - i hope you find it useful. A common reason why you end up with 2 terminal.exe services running is due to the multiple Sessions that exist in your Windows VPS environment. In order to further help you on how to resolve this, can you please let me know whether you get prompted, during your RDP connection, to choose which Session to use?