DX Unified Infrastructure Management

  • 1.  Alarm Creation in a Script Tied to Wrong Robot

    Posted Dec 09, 2016 11:04 AM

    I am trying to create an alarm in a script:

     

    nimbus.alarm(3, "Both Alarms are set","","", hostname)

     

    This creates the alarm with source and hostname both set correctly, but it uses the robot of the primary hub.  Consequently, when the alarm gets to SOI, it is listed with the primary hub instead of the alarming system.


    How do I get to be tied to the correct robot?



  • 2.  Re: Alarm Creation in a Script Tied to Wrong Robot

    Broadcom Employee
    Posted Dec 12, 2016 08:12 AM

       Have you tried setting the Ci type and Ci name?

    C:\Program Files (x86)\Nimsoft\bin>nimalarm -?
    usage: nimalarm [options] message-string
    where options are:
       -l <severity level>
       -s <subsystem id>
       -c <checkpoint id>
       -d <debug level>
       -S <source/hostname>
       -i - return message-id
       -1 <custom1>
       -2 <custom2>
       -3 <custom3>
       -4 <custom4>
       -5 <custom5>
       -t <CI type>
       -n <CI name>
       -m <CI metric>
       -a <alarm token>
       -V <message values e.g. key1=val1;key2=val2...>

     

    I believe this should help as the Ci information is used when going to these other systems.

     

    If not you may need to open an enhancement request for this.



  • 3.  Re: Alarm Creation in a Script Tied to Wrong Robot
    Best Answer

    Broadcom Employee
    Posted Dec 12, 2016 09:10 AM

    The issue you describe is a limitation of the nimbus.alarm call.

     

    Please see the following discussion regarding the creation of a raw alarm using LUA, which will help you to create alarms associated with a specific probe/robot:

     

    https://communities.ca.com/message/241894727?commentID=241894727#comment-241894727 



  • 4.  Re: Alarm Creation in a Script Tied to Wrong Robot

    Posted Dec 12, 2016 12:33 PM

    The raw alarm method works well. I've done something similar and depending on the final consumer of the alarm in your case you may find that you need to add more to the alarm than is in the sample code referenced. Best thing you can do is to use DrNimBus to dump the contents of an alarm that works the way you want your artificial alarm to work and then to add the necessary pieces to the PDS the sample code creates. As a for example, the sample doesn't populate the user tag values or the source hub and path. 

     

    -Garin



  • 5.  Re: Alarm Creation in a Script Tied to Wrong Robot

    Posted Dec 12, 2016 02:47 PM

    rawalarm is successfully creating alarms, but attempts to clear the same alarms using rawalarm or nimbus.alarm are failing.  Is there a similar script to clear one?



  • 6.  Re: Alarm Creation in a Script Tied to Wrong Robot

    Posted Dec 16, 2016 09:10 AM

    I got them to clear by making sure I used enough parameters in rawalarm, including dev_id and met_id.

     

    Thanks, everyone!