Community forum

Please note that VisualCron support is not actively monitoring this community forum. Please use our contact page for contacting the VisualCron support directly.


moegal
2008-11-24T17:35:39Z
Hi,

How would I create a job that will start a service after the server has rebooted? Seems I cannot add it to server start up. Then I will need to check on the service to see if it stops and restart after the initial start.

Thanks, Marty

Win2003 Server
Sponsor
Forum information
PeterW
2008-11-24T23:05:39Z
Hello,

I don't think there is a way to have VisualCron automatically start a service when the server reboots. There is a way you can get around this though. You could create a program that automatically starts with Windows and opens a simple flat file, modifies it, then saves it to the disk (for example: C:\StartService.txt). In VisualCron you can create a file trigger that watches the file for changes. Once the program saves the file the job will start and from there you can have it start the service. One suggestion I would have for your program is have it wait, say, 30 seconds before it modifies your file. That should give Windows enough time to start the VisualCron service. There is a little work involved however someone else may have other ideas.

The second part of your problem is easier. You can create a trigger that watches the status of the service. When the status is "stopped" VisualCron can restart the service.
moegal
2008-11-24T23:14:04Z
I was hoping this would be easy, we put in a request for this feature about a year ago via skype.

Can I just run a timer and start a service if it is not started?

Thanks, Marty
PeterW
2008-11-25T01:10:29Z
I suppose you could. You could have it run, say, once every 30 seconds or so. The problem is what will happen when VisualCron attempts to start a service that is already running? I don't know whether Windows will ignore the request, attempt to restart it, or throw an error.
Scroll to Top