SQL Agent Jobs

  • Hi all,

    I was wondering if anyone knew of a way to monitor a Agent job outside of SQL Agent mail.  We have had email problems where the email will be down and when an agent job fails there is no MSG sent.  I was thinking that if there were a way to have two agent jobs one the regular job and the other job monitor the first job and if it fails it would send a msg out via hotmail.  Then if email were down and the internet was up we would still get the msg failure?  Is there anyway to do this or if anyone can think of a way to monitor whether or not an agent job fails without email to notify a helpdesk or a pager/cell phone it would be a great help!

    Thanks!

    -NGS 

  • How many sql server do you have?  If you have only 1 sql server then I suggest that you don't use sql-mail because you can't set up a process to monitor it.

    If you have 2 or more you could set up a schedule task to send email from server A (using server B xp_cmdshell to send from A) to server B, have server B process it, If no email exist that mean server A didn't/can't/failed to send email.  xp_stopmail, xp_Startmail on server A and try to send sample email from Server A again and then have server B try to read it.  If all success it's all good.  If it fail to start sql-mail send a page to yourself that the email on server A is down.

    You do duplicate the same process and have server A check server B sql-mail.  The chance of having both of them down at the same time is much smaller then you think.

     

    mom

  • We have more than one SQL server.  Our SQL servers are up and we monitor that with whats up gold.  I am more concerned with the MAPI email servers that tend to go down.  I did find this extended Stored procedure to use SMTP which might be a better route for me to try. http://sqldev.net/xp/xpsmtp.htm  We have 3 SMTP servers with fail over capabilities. 

    I hate relying on email for notification for failures.  In our company it is not reliable.

    Thanks!

    -NGS

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply