Email alerts when server reboots

  • We had a external company set these email alerts up once we had a server reboot on any server. He is no longer with us and I won't to change who the email goes to but I can't find where he set this up. I've look at task scheduler, Event Viewer, Sql. Any thoughts is to where I could look?

  • If you haven't already, and this might take some work, check in the SQL Agent jobs. I've got several of my SQL Servers set up with a job that runs when the Agent starts to send me an e-mail. It's not perfect (if I manually re-start the Agent, I get an e-mail, if the Agent for some reason doesn't start, obviously I don't get an e-mail and can't know that I didn't get an e-mail...) but it works well enough.

  • I have checked all the jobs in the agent and I don't see one sending emails for server reboot.

  • lcarrethers (9/22/2016)


    I have checked all the jobs in the agent and I don't see one sending emails for server reboot.

    It's part of the schedule...

    Just make sure the service itself is set to automatically start.


    SELECT quote FROM brain WHERE original = 1
    0 rows returned

  • I guess i'm a bit confused. I don't have any jobs, I have lots of jobs that have this but they are all replication

  • lcarrethers (9/22/2016)


    I guess i'm a bit confused. I don't have any jobs, I have lots of jobs that have this but they are all replication

    Ok, do these jobs that you don't have but are really jobs related to replication have a step, probably the first step, that send out an email?

    Michael L John
    If you assassinate a DBA, would you pull a trigger?
    To properly post on a forum:
    http://www.sqlservercentral.com/articles/61537/

  • lcarrethers (9/22/2016)


    I guess i'm a bit confused. I don't have any jobs, I have lots of jobs that have this but they are all replication

    It could be a 3rd party monitoring tool.


    SELECT quote FROM brain WHERE original = 1
    0 rows returned

  • Look for a procedure that runs at startup:

    SELECT ROUTINE_NAME

    FROM MASTER.INFORMATION_SCHEMA.ROUTINES

    WHERE OBJECTPROPERTY(OBJECT_ID(ROUTINE_NAME),'ExecIsStartup') = 1

  • richard.bowles (9/22/2016)


    Look for a procedure that runs at startup:

    SELECT ROUTINE_NAME

    FROM MASTER.INFORMATION_SCHEMA.ROUTINES

    WHERE OBJECTPROPERTY(OBJECT_ID(ROUTINE_NAME),'ExecIsStartup') = 1

    Yeah, good thing to check...a proc could have been set to start using the 'sp_procoption' procedure.


    SELECT quote FROM brain WHERE original = 1
    0 rows returned

  • Found it. Thanks

  • Credits to Navy beans bet on it being a "Startup Proc". See the following for more details...

    https://www.google.com/?gws_rd=ssl#q=startup+procs+sql+server

    {edit} Apologies... didn't scroll down far enough. Didn't see Richard's post nor the fact that you found the culprit.

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

  • What was it? A startup trigger or something else?

    "The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
    - Theodore Roosevelt

    Author of:
    SQL Server Execution Plans
    SQL Server Query Performance Tuning

  • It was a stored proc

Viewing 13 posts - 1 through 12 (of 12 total)

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