Notification templates
Portax notification templates use Text::Template
to provide access to many variables injected from Portax monitoring subsystem. Read Text::Template's documentation on how to use templates.
Naming conventions
Notification template name is composed as mail/alert/<alert class>/<notification type>/<alert level (optional)>
.
- alert class
- alert class see below
- notification type
raise
orclear
- alert level
INFO
,FLAP
,WARN
orCRIT
, optional (omit last slash if not used)
Example
- mail/alert/DeviceDown/raise
-
Device [$element] is not responding.
- mail/alert/DeviceDown/clear
-
Device [$element] is responding again after [$duration].
Alarm attributes
- id
- alarm ID
- region_id
- region ID
- element_ip
- element's IP address
- if_id
- interface SNMP index (if applicable)
- element
- element's name
- class
- alarm class
- level
- alarm level
- raised
- raised datetime
- cleared
- cleared datetime
- duration
- alarm duration
- impact
- impacted subscribers count
- siblings
- impacted devices count
- element_id
- element ID
- note
- alarm note if available during raise (eg. maintenance event description)
Trigger attributes
- trigger_id
- trigger ID
- trigger_source
- Portax object class
- trigger_source_id
- Portax object ID
- trigger_threshold
- trigger threshold
- trigger_value
- current value
- trigger_enum
- enumerated valued
- trigger_operator
- trigger operator
- trigger_period
- trigger period
- trigger_object
- SNMP object name
- trigger_object_str
- SNMP object description (from MIB)
- trigger_match_meta
- trigger requires meta flag
Object attributes
Each Portax object class provides its own set of attributes.
Inventory device
- hostname
- device hostname
- ident
- device ident string
- model
- device model
- class
- device class
- description
- device description, aka note
- latlng
- device GPS
- address
- device address
- trigger_to
- notification recipients based on region
- tags
- device tags, comma separated
Interface
- if_type
- SNMP type
- if_admin_status
- SNMP admin status
- if_oper_status
- SNMP oper status
SNMP Traps
Alarms triggered by an SNMP trap have access to trap's varbind data, eg. coldStart trap:
DISMAN-EVENT-MIB::sysUpTimeInstance.=4537 SNMPv2-MIB::snmpTrapOID.0=coldStart SNMP-COMMUNITY-MIB::snmpTrapAddress.0=10.4.8.116 SNMPv2-MIB::snmpTrapEnterprise.0=es3510maMIB.101
any variable (eg. [$snmpTrapOID]
can be used in template).
Last modified
6 months ago
Last modified on Oct 11, 2023, 10:15:46 AM
Note:
See TracWiki
for help on using the wiki.