Skip to main content
Participating Frequently
May 6, 2008
Question

Scheduled task runs but doesn't work

  • May 6, 2008
  • 2 replies
  • 300 views
I have a scheduled task that calls a batch file that contains a 1 line java function that needs to be run periodically. If I go to the scheduler and run the task manually, it works without a problem. If I let the scheduler run the task automatically, it appears to run but doesn't actually call the java function. There are no errors in any of the CF logs and there is nothing in the windows event viewer. I tried pasting the url in a browser and it runs fine there as well. Does anyone have and idea as to how can I troubleshoot what's going on?

J.
    This topic has been closed for replies.

    2 replies

    Inspiring
    May 6, 2008
    JCox wrote:
    > I have a scheduled task that calls a batch file that contains a 1 line java
    > function that needs to be run periodically. If I go to the scheduler and run
    > the task manually, it works without a problem. If I let the scheduler run the
    > task automatically, it appears to run but doesn't actually call the java
    > function. There are no errors in any of the CF logs and there is nothing in
    > the windows event viewer. I tried pasting the url in a browser and it runs
    > fine there as well. Does anyone have and idea as to how can I troubleshoot
    > what's going on?
    >
    > J.
    >


    8.75 times out of 10 when you can run a piece of code that CF can't it
    is a permission issue. When you run it, your credentials are used.
    When CF runs it as a scheduled task, the credentials that CF is
    configured to run under, 'localSystem' is default on Windows, is used.

    Try running CF under a user with the necessary credentials to do what
    you want it to do.
    JCoxAuthor
    Participating Frequently
    May 6, 2008
    I forgot to mention that I am running CF 8. I tried putting on the 8.0.1 update and that didn't help either.