Win2008Server R2 – no window running .bat file via task scheduler

batch-filecommand-line-interfacetask-schedulerwindows-server-2008

I'm running a couple of batch files via Task Scheduler that call rsync.

The .bat files work great when run manually and appear to be running fine via TS as well. HOWEVER, it does NOT open a cmd window so I can visibly see the progress as it syncs the files.

I do NOT have them set as hidden. Is there any way to "turn the window on"? I'd like to be able to monitor what's going on (I'm just a control freak :P)

Best Answer

One of the gotchas of scheduled tasks is, that tasks can run as different users - essentially in their own session. They are usually not desktop-interactive processes. You can make this happen by making the task run only if the user is logged in. Another thing is that maybe you could create a batch task that starts the other batch files, there are different commands that allow you to specify how a batch file or executable runs. "start" is one that provides a bunch of options, "call" is another - for batch files specifically.

Another option is to try Yintersync (yinter.net), free, for Windows, works with rsync, is very stable, supports shadow copies. It was the only working solution I could find that was both stable and fast enough.