AIX Open Source

AIX Open Source

Share your experiences and connect with fellow developers to discover how to build and manage open source software for the AIX operating system

 View Only
  • 1.  net-snmp on AIX 7.1

    Posted Mon October 25, 2021 07:27 AM
    (Thread initially started in AIX community)
    I'm needing to replace CA's SysEDGE with an alternate snmptrap generator and @José Pina Coelho suggested net-snmp from the AIX toolbox which I downloaded (v5.8).

    When running /opt/freeware/sbin/snmptrapd I'm getting the following, I've seen other comments (lpar2rrd) stating that the latest net-snmp won't work with the native AIX sendtrap.

    exec(): 0509-036 Cannot load program /opt/freeware/sbin/snmptrapd because of the following errors:
            0509-150   Dependent module libpcre.a(libpcre.so.1) could not be loaded.
            0509-022 Cannot load module libpcre.a(libpcre.so.1).
            0509-026 System error: A file or directory in the path name does not exist.​


    Am I needing to install an older version of net-snmp (and if so where might that be) or is the issue I'm facing something that can be addressed?

    Many thanks, Steve

    ​​​


  • 2.  RE: net-snmp on AIX 7.1

    Posted Mon October 25, 2021 01:01 PM
    ** Update **

    Found I needed to install net-snmp-utils which now gives me snmptrap in /opt/freeware/bin.

    I then tried the below taken, in the main, from our existing SysEDGE "call" [I'm unsure of the "6 14" and wonder if its a SysEDGE specific item]

    /opt/freeware/bin/snmptrap -v 2c -c <community> <host>:162 \
    1.3.6.1.4.1.546.14.1.1 6 14 \
    1.3.6.1.4.1.546.14.1.1 "SAP_AIX_MONITOR" \
    1.3.6.1.4.1.546.14.1.3 " net-snmp " \
    1.3.6.1.4.1.546.14.1.4 "3" \
    1.3.6.1.4.1.546.14.1.8 "<Service Manager queue name>" \
    1.3.6.1.4.1.546.14.1.9 " Demo ticket to see if net-snmp Open Source works "​


    However I get

    Created directory: /var/net-snmp
    Created directory: /var/net-snmp/mib_indexes
    14: Bad variable type ("1")
    #
    


    Will keep digging.

    Thanks, Steve




  • 3.  RE: net-snmp on AIX 7.1

    Posted Tue October 26, 2021 11:36 AM
    1.3.6.1.4.1.546.14.1.1 6 14 \
    1.3.6.1.4.1.546.14.1.1 "SAP_AIX_MONITOR" \​

    I'd guess it's trying to process the 3rd argument (14) as an OID (which fails).

    Also note that both lines have the same OID, which makes no sense.



    ------------------------------
    José Pina Coelho
    IT Specialist at Kyndryl
    ------------------------------



  • 4.  RE: net-snmp on AIX 7.1

    Posted Tue October 26, 2021 11:48 AM
    José,

    Thanks for your note.  I think I've now managed to resolve things by using the below for v2 SNMP which is a little different from v1.  Agreed, the syntax where two lines are the same is odd it was lifted from the SysEDGE definition.

    /opt/freeware/bin/snmptrap -v 2c -c <community> <destination>:162 "" 1.3.6.1.4.1.546.14.1 \
    1.3.6.1.4.1.546.14.1.1 s "SAP_AIX_MONITOR" \
    1.3.6.1.4.1.546.14.1.3 s "<Ticket subject>" \
    1.3.6.1.4.1.546.14.1.4 s "<Ticket severity>" \
    1.3.6.1.4.1.546.14.1.8 s "<Service Manager queue name>" \
    1.3.6.1.4.1.546.14.1.9 s "<Ticket detail>"
    ​


    Many thanks, Steve




  • 5.  RE: net-snmp on AIX 7.1

    Posted Tue October 26, 2021 04:33 PM

    I can't find the ...14.1.1 part.

    Note that trap values were traditionally ill-defined.

    https://oidref.com/1.3.6.1.4.1.546.14.1

    http://www.mibdepot.com/cgi-bin/getmib3.cgi?win=mib_a&i=1&n=EMPIRE&r=cai&f=empire.mib&v=v1&t=tree#extensionGroup

    http://www.circitor.fr/Mibs/Html/E/EMPIRE.php



    ------------------------------
    José Pina Coelho
    IT Specialist at Kyndryl
    ------------------------------



  • 6.  RE: net-snmp on AIX 7.1

    Posted Tue October 26, 2021 04:45 PM

    Ok, this just in from a couple of musty neurons that have been twiddling their synapses for the past quarter century:

    In SNMPv1, there are 6 generic traps, numbered 0 through 5 (coldStart, warmStart, linkDown, linkUp, authenticationFailure, and egpNeighborLoss), and an enterprise-specific trap (numbered 6) where the "what is this trap" is a function of the trap OID, and specifc-trap field (14, in your case).

    https://www.ibm.com/docs/en/zos/2.2.0?topic=commands-snmp-trap-types



    ------------------------------
    José Pina Coelho
    IT Specialist at Kyndryl
    ------------------------------



  • 7.  RE: net-snmp on AIX 7.1

    Posted Thu February 03, 2022 07:51 AM
    José,

    I've managed to resolve my issue.  Long story short is that I was trying to send a v2 formatted trap to our SMARTS environment which is (only) expecting v1 formatted traps.

    My v1 formatted traps are now flowing into SMARTS with Service Manager tickets auto-cut from there.

    Regards, Steve