May 24, 2013 at 2:20 am
Hi,
I need your help to get information about sql service is stopped via mail.
May 24, 2013 at 2:35 am
I haven't actually tried this myself yet, but it should probably sort you out:-
http://sqlish.com/alert-when-sql-server-agent-service-stops-or-fails/
From within SQL Server itself, I don't believe you can send a mail when the service stops; but you can set up an Agent Job to send a mail with a schedule type of "Start automatically when SQL Server Agent Starts".
Follow me on twitter @EvoDBACheck out my blog Natural Selection DBA[/url]
May 24, 2013 at 2:45 am
Your best bet is to use some monitoring software such as SCOM (others are available). If you have to roll your own, I think you'd need to create a scheduled task in Windows to periodically check whether the SQL Server service is running and send an e-mail if it isn't.
John
May 24, 2013 at 3:08 am
Hi Matthew,
I have tried this but it is giving me error.
May 24, 2013 at 3:18 am
I use a combination of both SQL Agent e-mail alerts when the agent starts up and SCOM. What is the error message you are getting?
Joie Andrew
"Since 1982"
May 24, 2013 at 3:26 am
And following which of the two suggestions? As I said, I haven't actually tried the power shell mail within the windows service myself yet.
If it's the job step to send a mail, can you post the steps that you followed to create it and then the error message you received?
Follow me on twitter @EvoDBACheck out my blog Natural Selection DBA[/url]
May 27, 2013 at 4:34 am
Hi,
I have tried it like setting first recovery option for service --> run program
and there I have specified file location for windows task to send mail.
But it is asking me for authentication all the time.
Viewing 7 posts - 1 through 6 (of 6 total)
You must be logged in to reply to this topic. Login to reply