Hi Erick,
I have had some luck with the Execute on End, as well as other options such as Enterprise service managers outside of AE, but recently we have adopted, and recommended to all our clients the use of a VARA.SQLI. The reason is most organizations agents are changing rapidly, and we needed to provide each client with a system to use the current list, with the ability to filter out what we call "Bad Hosts", (agents that have either moved, or are being patched/upgraded/etc. The SQLI creates a current listing of all defined Agents, then feeds it to a "For Each" JOBP which runs 1 simple script that checks the listing of agents that are not supposed to be alive and once confirmed it is supposed to be alive, runs the following:
:IF SYS_HOST_ALIVE("&HOST#") = "N"
: SET &OUT# = SEND_MAIL("&MAIL",,"Agent &HOST# in &SYSTEM:&CLIENT is down","Agent &HOST# in &SYSTEM:&CLIENT is not active",)
:ENDIF
This JOBP is run every 30 minutes. This allows the system admins to update the "Bad Agent" list for not checking, and the email distribution list is from the standard notification list that we use for all other object failures. Let me know if you want more information.
------------------------------
Founder and Partner
Data Center Automation Consultants DCAC
------------------------------
Original Message:
Sent: 01-02-2020 11:00 AM
From: Erick Stevens
Subject: Agent Monitoring
How do I setup a mail notification to notify me when an agent has ended? I have seen our DB agents end abnormally and need to restart since I upgraded to 12.3. I believe the issue is related to how jobs are configured by one of our application teams but I need to have notifications when an agent is down so that we can restart them.
Also, is there a way that I can configure the job to start the DB agent again if it has ended abnormally?