So I have a trap that comes in from Avere that is formatted correctly:
Nov 16, 2017 10:55:43 AM EST A "fxtAlertOrCondition" event has occurred, from GnSNMPDev device, named someaveredevice.
Sent when the cluster posts a new alert or when a condition is set or cleared.
alertUuid = 1.23.22.0.4.0.11.0.92.3.0.25.90.0.5.0
alertUuid.alertIndex = 2
alertSeverity = yellow
We are adding a new attribute that we've imported from the MIB (alertDescription, 0xfff0188a) to the event to get more information. We created a procedure to do so:
0x052c0ade E 20 P " \
CreateEventWithAttributes( \
{ C CURRENT_MODEL }, \
{ H 0x052c1336 }, \
SetEventAttribute( \
GetEventAttributeList(), \
{ U 20 }, \
ReadAttributeInstance( { C CURRENT_MODEL }, { H 0xfff0188a }, \
GetEventAttribute( { U 0 } )) \
) \
)"
Works fine up to a point: since 0xfff0188a is instanced, we need to query that attribute based on the value of the "alertIndex" in the trap (alertUuid.alertIndex = 2, which is varbind 2); otherwise, it won't work.
How to embed the value of the instance from the trap so we can query the correct alertDescription for the new varbind 20 in the procedure?
In other words, alertDescription might look like this:
alertDescription.1 = "you had a problem on the disk"
alertDescription.2 = "you had an export problem"
alertDescription.3 = "you had a disk copy issue"
and if we got the trap:
Nov 16, 2017 10:55:43 AM EST A "fxtAlertOrCondition" event has occurred, from GnSNMPDev device, named someaveredevice.
Sent when the cluster posts a new alert or when a condition is set or cleared.
alertUuid = 1.23.22.0.4.0.11.0.92.3.0.25.90.0.5.0
alertUuid.alertIndex = 2
alertSeverity = yellow
we want the corresponding new event to look like so (alertIndex = 2):
Nov 16, 2017 10:31:13 AM EST A "fxtAlertOrCondition" event has occurred, from GnSNMPDev device, named someaveredevice
.
Sent when the cluster posts a new alert or when a condition is set or cleared.
alertUuid = 1.23.22.0.4.0.11.0.92.3.0.25.90.0.5.0
alertUuid.alertIndex = 2
alertSeverity = yellow
alertDescription = you had an export problem
Any thoughts on how to add that to our procedure above?
Thanks.