Using alarm fields for nas script or command parameters
search cancel

Using alarm fields for nas script or command parameters

book

Article ID: 372422

calendar_today

Updated On:

Products

DX Unified Infrastructure Management (Nimsoft / UIM)

Issue/Introduction

In a NAS Auto-Operator, what alarm fields can be passed as parameters to Lua scripts or "command" mode profiles?

Environment

DX UIM - All versions
nas probe - all versions

Resolution

The following fields are available to be read by a Lua script and may be passed as parameters.   They can also be passed as parameters to commands.

 

.source - source of the alarm (typically ip-address)
.hostname - resolved name (robotname or ip-address to name resolution)
.level - severity level (0-5)
.sid - subsystem identification.
.message - alarm message text.
.origin - origin of the alarm (stamped by nearest hub, or in some cases the robot.)
.domain - name of originating NimBUS domain.
.robot - name of the sending robot.
.hub - name of the nearest hub to the sending robot.
.prid - name of probe issuing the alarm.
.user_tag1 - user tag 1 (as set by robot).
.user_tag2 - user tag 2 (as set by robot).
.supp_key - suppression identification key.
.visible - flag for visibility (true = visible)

To pass commands to parameters, use $parameter format.

 

Of these, the following fields are able to be set by a script:

.message
.level
.sid
.source
.hostname
.user_tag1
.user_tag2
.visible
.custom_1 to custom_5
.supp_key
.origin

In a script that is used by an Auto-Operator, these are accessed as part of the "alarm" context:

 

 

In a script that is run by a Pre-Processor they are accessed in the "event" context:

 

 

Additional Information

More information, including basic LUA documentation, can be found in the following article:

Need detailed documentation or whitepaper about the lua database commands in the nas probe