Syslog
Configure Syslog Escalation Action
Available in HQ Open Source unless marked by * for HQ Enterprise only
You can configure HQ to write to systlog log as part of an escalation scheme.
This option is only available with syslog is explicitly enabled.
If you choose syslog as an escalation step, you supply values for elements of the the log message: Meta, Version, and Product. When the escalation action is performed, HQ will log a line of the following format:
SyslogAction[ALERT_ID]: DB_1 4 META/PRODUCT/VERSION RESOURCE_NAME : ALERT_NAME - ALERT_CONDITION
where:
- ALERT_ID = a number representing the alert ID in HQ.
- META = The user-entered string for Meta in the escalation scheme action
- PRODUCT = The user-entered string for Product in the escalation scheme action
- VERSION = The user-entered string for Version in the escalation scheme action
- RESOURCE_NAME = The resource name in HQ
- ALERT_NAME = The name of the alert that was triggered
- ALERT_CONDITION = The alert condition and current value (for example, "If Availability > 0.0 (actual value = 1)")
If you have any comments or suggestions for this help page, please submit them at the bottom of the page by clicking Add Comment.
Prerequisites
- syslogd must be enabled to accept remote logging, even on localhost. This is usually done by passing -r to syslogd at startup.
- The Facility in HQ_SERVER_HOME/conf/templates/log4j.xml (LOCAL7 in the example below) must be a syslog-configured facility.
Enabling Logging via Syslog
To enable escalation-action logging via syslog:
Note: In this file, the appenders need to be grouped together, and the categories need to be grouped together.
1. Add (or uncomment) the following block in log4j.xml.
<appender name="SYSLOG" class="org.apache.log4j.net.SyslogAppender"> <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/> <param name="Facility" value="LOCAL7"/> <param name="FacilityPrinting" value="true"/> <param name="SyslogHost" value="localhost"/> <layout class="org.apache.log4j.PatternLayout"> <param name="ConversionPattern" value="%c{1}[%r]: %m%n"/> </layout> </appender>
2. Add (or uncomment) the following block in log4j.xml.
<category name="org.hyperic.hq.bizapp.server.action.log.SyslogAction"> <priority value="INFO" /> <appender-ref ref="SYSLOG"/> </category>
3. Restart HQ.
After restart, the Syslog option will be available when defining an escalation scheme.
|
Related Topics Alert escalation |
Associated UI Pages |
Return to the alerts overview.
Comments ( Hide )
Anonymous says:Feb 01, 2008 05:42 ( Permalink ) |
Anonymous says:The tag: <category name="net.hyperic.hq.bizapp.server.action.log.SyslogAction"> should come after all <appender.../appender> -tags (i.e. group appenders, then group categories together). |
<priority value="ERROR" /> works not everytime. You could experiment with "WARNING" or "INFO" instead.