SMARTS - 10.1.x
SMARTS DM - 2.X
TCSA - 2.X
<BASEDIR>/SAM/smarts/local/conf/icoi/trap_mgr.conf
# Custom Trap
BEGIN_TRAP .1.22.333 * *
ElementName: $V2-ServerName$
SysNameOrAddr: $V2-IP$
SuppressAgentAsOccurredOn: TRUE
EventName: $V3$
InstanceName: $V2$ $V6$
ClassName: Hyperic
ClearOnAcknowledge: FALSE
LogFile: Hyperic.log
UserDefined1: $V1$
UserDefined2: $V4$
UserDefined3: $V6$
UserDefined4: $V2-ServerName$
Severity: $V5-Sev$
# Name: $V6$
Expiration: 600
# Change severities
# Local element name mapping.
Map:{
V5-Sev
1=3
2=2
3=1
}
{
V2-ServerName
}
{
V2-IP
END_TRAP
Adding ElementClassName to the custom trap, helps SMARTS identify the type of Device and propagate the trap details to the Notification Log Console.
Below is the correct trap definition to achieve the same :# Custom Trap
BEGIN_TRAP .1.22.333 * *
ElementName: $V2-ServerName$
SysNameOrAddr: $V2-IP$
SuppressAgentAsOccurredOn: TRUE
EventName: $V3$
ElementClassName : Host
InstanceName: $V2$ $V6$
ClassName: Hyperic
ClearOnAcknowledge: FALSE
LogFile: Hyperic.log
UserDefined1: $V1$
UserDefined2: $V4$
UserDefined3: $V6$
UserDefined4: $V2-ServerName$
Severity: $V5-Sev$
# Name: $V6$
Expiration: 600
# Change severities
# Local element name mapping.
Map:{
V5-Sev
1=3
2=2
3=1
}
{
V2-ServerName
}
{
V2-IP
}
END_TRAP
The above trap definition is an example on how to map Device Name and Device IP to the device.