Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Timeout for JOBS

Status
Not open for further replies.

beechill4

Technical User
May 10, 2005
207
0
0
IE
Hi,

I wish to have a timeout period for all my sql server (2005) jobs. I have gone into the properties of SQL Server agent in mgmt studio and set the job system timeout to 600 seconds but some jobs continue to run for over 1 hour.

Can someone offer some advice please?

Thanks

 
I'm not sure what setting it is that you've changed. I do not know of any setting to control how long the SQL Server Agent Jobs are allowed to run.

One approach that some people are using is to create a special monitor job that keeps track of the other jobs.

Another approach that could be useful in some scenarios is to use the SET LOCK_TIMEOUT setting in the start of your T-SQL job step. This means that if the job is hanging because of that a table is locked, then the job fails after the specified time.

I'm using SET LOCK_TIMEOUT in my index optimization stored procedure.

Ola Hallengren
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top