0

How do I run a program from a server?

Hello. Just to clarify what I am asking: I want to write a lightweight program to manage my forum. Because there are not enough settings in the forum to do everything I need. So the program will parse and send emails depending on what is being posted (with prior permission of course). The program must run every minute and check the forum status. I want a program to run 24/7. So I need it on a server I think. Can I do this on any server? Its only very lightweight. It will be an exe file. Can I just transfer it to any hosting service and then execute it, so it continuously runs there (parsing my forum every minute)?

Thanks :)

2
  • doesn't sound lightweight to me... it also most likely won't be an .exe file
    – Tyson
    Commented Jul 25, 2014 at 16:34
  • Hi. Re duplicate: last question got put on hold for not being specific, I edited as requested but still on hold so I reposted. Re. lightweight: I think I can make it into an exe file. Just has to load the HTML from my forum, parse the info, then send out some emails.
    – Danny
    Commented Jul 25, 2014 at 16:42

1 Answer 1

0

Of course, there are several ways to do this.

If it is linux server you can set a cron job to be executing your program every x time interval.

If it is a windows server you can use the Windows Task Scheduler to execute your program every x time interval.

One thing to be aware of is if the program you want to execute is not in the same server than the one serving the forum you will need to find a way to connect to it and extract the required info.

For this, depending from your needs, you can simply allow remote connections from you database server or maybe set up a url that makes the work for you and just parse the info.

5
  • Thanks Gaston. Do you know if it has to be a VPS or dedicated server? If I get a VPS and install my wordpress on it then will they then be on the same server? this cold be ideal.
    – Danny
    Commented Jul 25, 2014 at 16:46
  • A VPS will work. I would put both in the same server :) Commented Jul 25, 2014 at 16:48
  • Can you explain how to use the Cron service, or Task Scheduler? Right now, this is just saying to use a program, but no instructions. Please edit to include more information. Thanks Commented Jul 25, 2014 at 16:54
  • I think there is enough info already on internet to figure this out. However if you want a more precise answer would be better to give more precise requirements. I gave an equally precise answer as the question asked. Commented Jul 25, 2014 at 16:56
  • I think Gaston did answer my question. But I already know how to have the program run on the server: have a timer in the program that executes commands based on a certain time interval (Cron), or with task scheduler: the operating system executes the program after certain amount of time or events. Not sure if thats what it means but I can do both. Guess I wasn't sure how to start a program on a regular hosted server, but since I'm sold on the VPS idea i gues it doesn't matter :) So thanks for the answers, I'm off to get a vps :) sorry i cant upvote yet cause <15 rep
    – Danny
    Commented Jul 25, 2014 at 17:10

Not the answer you're looking for? Browse other questions tagged .