The SNMP event forwarding feature is included as part of the LifeKeeper core functionality, and does not require additional LifeKeeper packages to be installed. It does require that SNMP software be installed on each LifeKeeper node that will generate trap notification of LifeKeeper events. LifeKeeper uses the snmptrap utility to generate the traps. This utility is provided by the ucd-snmp-utils package on most Linux distributions (called ucdsnmp on SuSE).
In older versions of the ucd-snmp implementation (prior to 4.1) where the defCommunity directive is not supported, the traps will be sent using the "public" community string.
It is not necessary to have an SNMP agent snmpd running on the LifeKeeper node.
The configuration of a trap handler on the network management console and its response to trap messages is beyond the scope of this LifeKeeper feature. See the documentation associated with your system management tool for related instructions.
The following tasks must be performed to set up LifeKeeper SNMP Event Forwarding. All but the last task must be repeated on each node in the LifeKeeper cluster that will be generating SNMP trap messages.
Ensure that the snmptrap utility is available as noted above.
Specify the network management node to which the SNMP traps will be sent. This can be done either by command line or by editing the /etc/default/LifeKeeper file. You must specify the IP address rather than domain name to avoid DNS issues.
By command line, use the lk_configsnmp (see the lk_configsnmp(1M) man page for details). This utility will only accept IP addresses.
Or, edit the defaults file /etc/default/LifeKeeper to add the IP address. Search for the entry LK_TRAP_MGR= and insert the IP address to the right of the = (no white space around the =).
If you are using
an older version of the ucd-snmp implementation that
does not support the defCommunity directive, skip this step. Traps will
be sent using the "public" community string. Otherwise, do the
following:
Specify a default community in /usr/share/snmp/snmp.conf.
If this file does not exist, create it using sufficiently secure permissions.
Add the
directive "defCommunity"
with a value. This
specifies the SNMP version 2c community string to use when sending traps.
For example,
add a line like this:
defCommunity myCommunityString
Refer to the snmp.conf
man page (delivered with the ucd-snmp
package) for more information about this configuration file.
Perform whatever configuration steps are needed on the remote management console to detect and respond to the incoming trap OIDs from LifeKeeper events. If the management node is a Linux server, the minimum that you would need to do to begin verification of this feature would be to start the snmptrapd daemon with the -P option (print the messages to stdout).
To verify that the configuration is working, initiate a LifeKeeper action (for example, start or stop LifeKeeper, or bring a resource in-service manually using the LifeKeeper GUI). Verify that the trap message was received at the management console. If a trap is not received, inspect the appropriate log files on the management system, and follow the normal troubleshooting practices provided with the management software. The LifeKeeper SNMP log can be inspected to determine if there was a problem sending the trap message. See SNMP Troubleshooting for more information.
To disable the generation of SNMP traps by LifeKeeper, simply remove the assignment of an IP address from the LK_TRAP_MGR environment variable in the file /etc/default/LifeKeeper. This can be accomplished using the lk_configsnmp utility from the command line with the "disable" option (see the lk_configsnmp(1M) page for an example). Or, edit /etc/default/LifeKeeper and change the entry for LK_TRAP_MGR to LK_TRAP_MGR= (or remove the line entirely). This must be done on each node that should be disabled from sending trap messages.
See Also