...
- Configuration for Notifications to a specific System Monitor
- Specifies the type of notification: "service_name_on_error" or "service_name_on_success"
- Specifies the service status of notification: "service_status_on_error" or "service_status_on_success"
- Specifies then the EXACT name of the service (the way it is named at the System Monitor)
- Specifies the EXACT hostname for the host the notification are sent from (the way it is named at the System Monitor)
- Specifies the port the application to receive passive checks is running on
- Specifies the hostname of the System Monitor, that is the hostname for the host the notification are sent from
- Define the type of encryption is used to send the information to the System Monitor
- Specifies how many notifications have to be sent to the System Monitor for a specific Job Scheduler object
- The same as above in case there is configured a Timer for this Job Scheduler object
...
Code Block | ||
---|---|---|
| ||
<?xml version="1.0" encoding="utf-8"?> <SystemMonitorNotification xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="SystemMonitorNotification_v1.0.xsd"> <Notification> <NotificationMonitor service_name_on_error="OMS Mass Processing Problem Tracking"><Notification> <!-- configure system monitor service <NotificationInterface service_host="OMS Interfacing Server" monitor_port="5667" monitor_host="dipsy.sos" monitor_encryption="XOR">order history id=%ORDER_HISTORY_ID%, job chain=%JOB_CHAIN_NAME%, order id=%ORDER_ID%, step =%ORDER_STEP_STATE%, error=%ERROR_TEXT%, check = %CHECK_TEXT%</NotificationInterface> </NotificationMonitor> name and command for send notification to OP5 system monitor using nsca client notification command substitution in this case: <NotificationObject> <JobChains> <JobChain scheduler_id="scheduler" notifications="20" name="MY_JOB_CHAIN_NAME"/> </JobChains> <Timers> <Timer> <JobChains> <JobChain notifications="20" name="MY_JOB_CHAIN_NAME"/> </JobChains> </Timer> </Timers> </NotificationObject> </Notification> <Notification> <NotificationMonitor service_name_on_success="OMS Mass Processing History"> <NotificationInterface service_host="OMS Interfacing Server" monitor_port="5667" monitor_host="dipsy.sos" monitor_encryption="XOR">order history id=%ORDER_HISTORY_ID%, job chain=%JOB_CHAIN_NAME%, order id=%ORDER_ID%</NotificationInterface> </NotificationMonitor> %SERVICE_NAME% Error Service (service_name_on_error) %SERVICE_STATUS% 1 if error occured (service_status_on_error) 0 if error recovered (service_status_on_success) %SERVICE_MESSAGE_PREFIX% ERROR if error occured RECOVERED if error recovered TIMER if performance check %ORDER_HISTORY_ID% ... table field name of result row for building message (see table definition SCHEDULER_MON_NOTIFICATIONS) --> <NotificationMonitor service_name_on_error="Error Service" service_status_on_error="1" service_status_on_success="0"> <NotificationCommand><![CDATA[cmd /c echo my_nsca_service_host:%SERVICE_NAME%:%SERVICE_STATUS%:%SERVICE_MESSAGE_PREFIX%history id=%ORDER_HISTORY_ID%, step =%ORDER_STEP_STATE%, error=%ERROR_TEXT%, check = %CHECK_TEXT% | C:\nsca\send_nsca.exe -H nsca_server_host -c C:\nsca\send_nsca.cfg -d : ]]></NotificationCommand> </NotificationMonitor> <NotificationObject> <!-- configure job chains and count send operations for sending error/recovered notifications requirement: monitoring of this job chains must be configured in CheckHistoryConfiguration.xml --> <JobChains> <JobChain notifications="10" name="samples/sample_jobChain_1"/> <JobChain notifications="10" name="samples/sample_jobChain_2"/> </JobChains> <Timers> <Timer> <!-- configure job chains and count send operations for sending performance notifications requirement: timer check for this job chain must be configured in CheckHistoryConfiguration.xml --> <NotificationObject> <JobChains> <JobChain scheduler_id="scheduler" <JobChain notifications="201" name="MYsamples/sample_JOBjobChain_CHAIN_NAME1"/> </JobChains> </Timer> </NotificationObject>Timers> </Notification>NotificationObject> </Notification> </SystemMonitorNotification> |
...