Search code examples
sqlsql-serversql-server-2008sql-job

Sql Job running for 30 minutes then report successful


We have a job that runs every night and rebuild the indexes on a customer database, however after installing the job, it runs successfully every night according to the history and finishes in around 30 minutes every night, however we found that the indexes that it should fix, are not actually fixed and still fragmented above the allowed level.

Is there anything that would stop a job from running more then 30 minutes? It currently doesn't have an end date on it.


Solution

  • The end date is about when a schedule (for determining when to start the job) should cease to be valid. There is a Shutdown Timeout setting in Sql Server Agent Properties, but that defaults to 15 seconds, and is about completing shutdown, rather than total execution time.

    So...

    Have you run the script manually?

    How long does it take to complete?

    Does it complete successfully according to your standards?

    Related: