Results 1 to 4 of 4

Thread: Monitoring Long Running Jobs

  1. #1
    Join Date
    Nov 2002
    Posts
    36

    Monitoring Long Running Jobs

    Hello,

    Can anyone help me how to monitor and send notifications for long running jobs or the jobs which has hanged in the middle. sysjobhistory tbl gives detail about success or failure of the job.

    Any help is appreciated

    Thanks
    Sejal

  2. #2
    Join Date
    Oct 2003
    Location
    Germany
    Posts
    1

    Talking

    Hello,
    found a script at sqlservercentral.com.
    Not sure if this is the solution you need.

    Try this link:


    Find Longstanding Open Transactions

    Brgds...MipMip

  3. #3
    Join Date
    Sep 2002
    Location
    Fantasy
    Posts
    4,254
    1. create a table in MSDB like below

    JobName Start ExpTime started Ended
    x 10:00AM 15
    y 11:00pm 70

    2.In the job

    1st step. update the started with true and ended with NULL
    2nd step. real job step
    3rd step. update the ended with True

    3. create another job which runs every 5 mins which can check this table and compare the getdate() and startime+expectedtime and started.
    This job can send message if it is running for a long time

  4. #4
    Join Date
    Nov 2002
    Posts
    36
    HAPPY DIWALI

    Thanks A Lot
    Sejal

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •