Chapter 4. Simple Network Management Protocol

The Simple Network Management Protocol (SNMP) is part of the Internet protocol suite, as defined by the Internet Engineering Task Force (IETF). The SNMP provides a means to monitor and manage network-attached devices. For general information about SNMP, see http://www.snmplink.org/ .

This section describes the snmpd-uv(8) agent which is the SGI SNMP agent for Altix UV 100 and 1000 series systems. The snmpd-uv(8) agent is only available on the System Management Node (SMN) node.

SNMP Agent Overview

The snmpd-uv(8) agent fetches configuration information from the System Controller (SYSCO) network attached to the System Management Node (SMN). The SYSCO network contains all the Chassis Management Controller (CMC) and Base Management Controller (BMC) and accessories, such as, the I/O expansion chassis.

The snmpd-uv(8) agent supports multiple Altix UV systems attached to the SMN.

The snmpd-uv(8) retrieves information stored in a MySQL database by translating SNMP pass_persist GET and GETNEXT OID requests into equivalent MySQL SELECT queries on appropriate tables corresponding to those defined in the Altix UV SNMP.

The snmpd-uv(8) agent does not perform data gathering or MySQL tables update operations. Instead, two additional services are used in tandem to perform the following:

  • Data gathering

    A system daemon, called uv_gather, collects information from the SYSCO network attached to the SMN. After parsing the data in a readable format, it pushes the data to another system daemon, uv_db, to perform MySQL updates.

  • MySQL Tables updates

    A system daemon, uv_db, is responsible for receiving data from uv_gather and performs appropriate MySQL tables update.

Since the snmpd-uv(8) agent does not perform data gathering, it is important to make sure the uv_gather and uv_db services are enabled in order to get up-to-date information from the periodically updated MySQL Altix UV database (see “Verifying the SMN Software Stack”). The uv_gather and uv_db services are normally setup to start at boot time.

The SNMP Agent companion services maintain information of all the Altix UV nodes attached to the SMN. They also fetch environmental information, such as, fan speed and voltage margins. For further details, please consult the management information base (MIB) file that comes with the package.

The snmpd-uv(8) agent can also send trap if the configuration file contains trapsink or trapsink2 directives.


Note: The current version of the agent does not yet support sending traps. This functionality will be offered in future updated version of the agent. Instead, the user can still use the NET-SNMP DISMAN Net-SNMP standard embedded sub-agent facilities to perform various trap configuration.

Normally, the snmpd-uv(8) agent is not manually invoked. It is actually invoked by snmpd(8) daemon via a configuration file. See “SNMP Configuration”.


Verifying the SMN Software Stack

The smn_info_gather script is the most complete and preferred method of verifying the SMN software stack. When the system_info_gather script (provided by the sgi-support-tools package in the SGI Foundation Software product) is run, it automatically calls the smn_info_gather script on SMN nodes as well.

There are several ways to verify that the system management node (SMN) software stack is operating properly, as follows:

  • To perform a sanity test on the various SMN software components, perform the following:

    uv44-smn:~ # /usr/sbin/smn_info_gather -h
    Usage: smn_info_gather [ options] [test1 test2 ...]
    Options:
      -h        this help message
      -s        show test(s) it would run
    Tests Group:
      all       : restart install running info dump dumpfull gather snmp
      restart   : restart
      install   : release rpm chkconfig sysco
      running   : sysco sysco_mount running cmc_ping console
      info      : release sysco_system sysco_topology sysco_release rpm_info sysco_info
      dump      : dump
      dumpfull  : dumpfull
      gather    : release sysco_system sysco_topology sysco_release rpm rpm_info chkconfig sysco_info
                  sysco sysco_mount running snmp
      snmp      : snmp
    Default test: gather
    
    Available individual tests:
    release rpm chkconfig sysco restart sysco sysco_mount running cmc_ping console release sysco_system
    sysco_topology sysco_release rpm_info sysco_info

    uv44-smn:~ # smn_info_gather running
    check_sysco              :
            sysco                     user exist               : Pass
            /sysco                    home exist               : Pass
    check_sysco_mount        :
            /sysco/hw/.fuse           mount exist              : Pass
    check_console            :
    
            /sysco/bin/uv_con         exist                    : Pass     1 /sysco/uv_con/old/UV-00000
    014:partition000.log-20110608.bz2       21324 2011-06-08 14:00
         2  /sysco/uv_con/old/UV-00000044:partition000.log-20110608.bz2     18994 2011-06-08 14:00
         3  /sysco/uv_con/old/UV-00000014:partition000.log-20110607.bz2     21324 2011-06-07 14:00
         4  /sysco/uv_con/old/UV-00000044:partition000.log-20110607.bz2     18994 2011-06-07 14:00
         5  /sysco/uv_con/old/UV-00000044:partition000.log-20110606.bz2     18994 2011-06-06 14:00
         6  /sysco/uv_con/UV-00000014:partition000.log      117527 2011-06-05 23:23
         7  /sysco/uv_con/UV-00000014:partition000.log.1    117527 2011-06-05 23:20
         8  /sysco/uv_con/old/UV-00000044:partition000.log-20110605.bz2     18994 2011-06-05 14:00
         9  /sysco/uv_con/old/UV-00000044:partition000.log-20110604.bz2     18994 2011-06-04 14:00
        10  /sysco/uv_con/old/UV-00000044:partition000.log-20110603.bz2     18994 2011-06-03 14:00
        11  /sysco/uv_con/old/UV-00000044:partition000.log-20110511.bz2     18994 2011-05-11 14:00
        12  /sysco/uv_con/old/UV-00000044:partition000.log-20110510.bz2     18994 2011-05-10 14:00
        13  /sysco/uv_con/old/UV-00000044:partition000.log-20110509.bz2     18994 2011-05-09 14:00
        14  /sysco/uv_con/old/UV-00000044:partition000.log-20110508.bz2     18994 2011-05-08 14:00
        15  /sysco/uv_con/old/UV-00000044:partition000.log-20110507.bz2     18994 2011-05-07 14:00
        16  /sysco/uv_con/old/UV-00000044:partition000.log-20110506.bz2     18994 2011-05-06 14:00
        17  /sysco/uv_con/old/UV-00000044:partition000.log-20110505.bz2     18994 2011-05-05 14:00
        18  /sysco/uv_con/old/UV-00000044:partition000.log-20110504.bz2     18994 2011-05-04 14:00
        19  /sysco/uv_con/old/UV-00000044:partition000.log-20110428.bz2     18994 2011-04-28 14:00
        20  /sysco/uv_con/old/UV-00000044:partition000.log-20110427.bz2     18994 2011-04-27 14:00
        21  /sysco/uv_con/old/UV-00000044:partition000.log-20110426.bz2     18994 2011-04-26 14:00
        22  /sysco/uv_con/old/UV-00000044:partition000.log-20110425.bz2     18994 2011-04-25 14:00
        23  /sysco/uv_con/old/UV-00000044:partition000.log-20110424.bz2     18994 2011-04-24 14:00
        24  /sysco/uv_con/old/UV-00000044:partition000.log-20110423.bz2     18994 2011-04-23 14:00
        25  /sysco/uv_con/old/UV-00000044:partition000.log-20110422.bz2     18994 2011-04-22 14:00
        26  /sysco/uv_con/old/UV-00000044:partition000.log-20110421.bz2     18994 2011-04-21 14:00
        27  /sysco/uv_con/old/UV-00000044:partition000.log-20110420.bz2     18994 2011-04-20 14:00
        28  /sysco/uv_con/old/UV-00000044:partition000.log-20110419.bz2     18994 2011-04-19 14:00
        29  /sysco/uv_con/old/UV-00000044:partition000.log-20110418.bz2     18994 2011-04-18 14:00
        30  /sysco/uv_con/old/UV-00000044:partition000.log-20110417.bz2     18994 2011-04-17 14:00
        31  /sysco/uv_con/old/UV-00000044:partition000.log-20110416.bz2     18994 2011-04-16 14:00
        32  /sysco/uv_con/old/UV-00000044:partition000.log-20110415.bz2     18994 2011-04-15 14:00
        33  /sysco/uv_con/old/UV-00000044:partition000.log-20110414.bz2     18994 2011-04-14 14:00
        34  /sysco/uv_con/old/UV-00000044:partition000.log-20110413.bz2     18994 2011-04-13 14:00
        35  /sysco/uv_con/UV-00000044:partition000.log      92108 2011-04-01 16:33
        36  /sysco/uv_con/old/UV-00000044:partition000.log-20110401.gz      19728 2011-04-01 16:33
        37  /sysco/uv_con/old/UV-00000044:partition000.log-20110328.gz      19771 2011-03-28 11:55
    Pass
    check_running            :
            status                    monit                    : Pass
            status                    named                    : Pass
            status                    dhcpd                    : Pass
            status                    smnd                     : Pass
            status                    syscofs                  : Pass
            status                    mysql                    : Pass
            status                    smn_uv_db                : Pass
            status                    smn_uv_gather            : Pass
            daemons                   named                    : Pass
            daemons                   dhcpd                    : Pass
            daemons                   smnd                     : Pass
            daemons                   syscofs                  : Pass
            daemons                   mysqld                   : Pass
            daemons                   uv_db                    : Pass
            daemons                   uv_gather                : Pass
            daemons                   logman                   : Pass
            monit                     smnd                     : Pass
            monit                     syscofs                  : Pass
            monit                     syscofs_mount            : Pass
            monit                     uv_db                    : Pass
            monit                     uv_gather                : Pass
            /usr/bin/pmdate           exist                    : Pass
            logs exist                /var/log/smnd.log        : Pass
                                       ...
    

  • To display the status of the various SMN daemons running on the SMN, perform the following:

    uv44-smn:~ # monit status
    The Monit daemon 5.0.3 uptime: 61d 16h 59m
    
    Process 'syscofs'
      status                            running
      monitoring status                 monitored
      pid                               21262
      parent pid                        1
      uptime                            47d 16h 55m
      children                          0
      memory kilobytes                  1388
      memory kilobytes total            1388
      memory percent                    0.0%
      memory percent total              0.0%
      cpu percent                       0.0%
      cpu percent total                 0.0%
      data collected                    Tue Apr 26 12:37:24 2011
    
    File 'syscofs_mount'
      status                            accessible
      monitoring status                 monitored
      permission                        444
      uid                               0
      gid                               0
      timestamp                         Tue Mar 15 11:20:28 2011
      size                              0 B
      data collected                    Tue Apr 26 12:37:24 2011
    
    Process 'smnd'
      status                            running
      monitoring status                 monitored
      pid                               21351
      parent pid                        1
      uptime                            47d 16h 55m
      children                          0
      memory kilobytes                  2115648
      memory kilobytes total            2115648
      memory percent                    35.3%
      memory percent total              35.3%
      cpu percent                       0.0%
      cpu percent total                 0.0%
      data collected                    Tue Apr 26 12:37:24 2011
    
    Process 'uv_gather'
      status                            not monitored
      monitoring status                 not monitored
      data collected                    Tue Apr 26 12:37:24 2011
    
    Process 'uv_db'
      status                            not monitored
      monitoring status                 not monitored
      data collected                    Tue Apr 26 12:37:24 2011
    
    System 'localhost'
      status                            running
      monitoring status                 monitored
      load average                      [0.04] [0.05] [0.01]
      cpu                               0.3%us 0.3%sy 0.0%wa
      memory usage                      3406740 kB [56.9%]
      data collected                    Tue Apr 26 12:37:24 2011

  • You can access the monit status at a web browser interface at http://admin:11110.

SNMP Configuration

In order to integrate the snmpd-uv agent into snmpd, two configuration methods are available, as follows:

Automatic Configuration Using uv_snmpconfig

This is the easiest and recommended method. The uv_snmpconfig command performs all the configuration steps explained in the manual configuration section below. It also offers an option to test the configuration consisting in verifying:

  • MIB translation of Object Identifiers (OIDs) using snmptranslate.

  • The SNMP agent can snmpwalk the entire uv SNMP agent SQL database

  • Basic and configured (if relevant) traps are captured.

To view the uv_snmpconfig(8) man page, perform the following:

uv41-smn:~ # man uv_snmpconfig
SGI SNMP(8)                                                       SGI SNMP                                SGI SNMP(8)



NAME
       snmpconfig - SGI SNMP Agent configuration utility

SYNOPSIS
       a4700_snmpconfig [options]        xe_snmpconfig [options]
       uv_snmpconfig [options]

DESCRIPTION
       snmpconfig configures SNMP configurations files for the desired SNMP agent.
       Depending on the selected agent, some may require additional parameters as
       illustrated in the SYNOPSIS section.

IMPORTANT NOTES
       1      snmpconfig cannot configure 2 agents at the same time.

       2      snmpconfig will destroy any SNMP previous configurations when -f is used.
              Please use -r to save a backup.

OPTIONS
       -h     This help message

       -f     Overwrite configuration files

       -c     Configure SNMP.

       -t     Test SNMP. Consists in, for the selected agent MIB:

               1.  snmptranslate

               2.  snmpwalk

               3.  snmptable for each Table found in the MIB

       -r     Restore SNMP configuration files when -c option is used.

AGENTS
       1. a4700
              Requires the IP address or the hostname of the L2 controller

       2. xe  Require no argument.

       3. uv  Require no argument.

COPYRIGHT
       Copyright © 2009-2011 Silicon Graphics Inc.

SEE ALSO
       snmpd(8), snmptrapd(8), snmptranslate(1), snmpwalk(1), snmptrap(1), snmp.conf(5),
       snmpd.conf(5), snmpcmd(1), snmptrapd.conf(5)



Agent Configuration                                             June 6, 2011                                SGI SNMP(8)


Note: The utility will not overwrite already installed SNMP configuration files unless the command-line option -f (force) is used. However, in most cases, although the utility backs up files before overwriting them (when -f is used ), it is recommended to make a copy of the configuration files before proceeding. Use the -r option to save a backup. uv_snmpconfig is a generic script for all the agents supported by SGI.


Manual Configuration

To manually configure the SNMP agent, three steps are required, as follows:

  1. Integrate the agent MIB.

    On RHEL, modify or create the snmpd /etc/snmp/snmpd.options file. The easiest is to make sure the following start-up parameters are defined:

    # Original option
    OPTIONS="-Lsd -Lf /dev/null -p /var/run/snmpd.pid -a"
    
    # Adding SGI agent
    OPTIONS="${OPTIONS} -M +/opt/sgi/snmpagents/mibs -m ALL"

    On SLES, the /opt/sgi/snmpagents/mibs/sgi-uv-smi.mib should be copied to /usr/share/snmp/mibs/ directory. Also, if not already done, the remaining /opt/sgi/snmpagents/mibs/ files should also be copied.

    Optionally, apply the same changes in the global /etc/snmp/snmp.conf file by adding the following two lines:

    mibs            ALL
    mibdirs         +/opt/sgi/snmpagents/mibs

  2. Configure agent configuration file.

  3. This is where the agent is actually called by snmpd(8) using the pass_persist protocol. Also, this is where various monitored events are defined. The file itself contains configuration instructions.

    Copy or append /opt/sgi/snmpagents/etc/snmpd.uv.conf to /opt/sgi/snmpagents/etc/snmpd.local.conf. Do NOT edit the file directly as it can be replaced later by an RPM package update.

    Finally, if NET-SNMP DISMAN facilities are used and you want to change monitoring intervals, the monitor -r 300 lines should be changed.

    You also have to specify the -c /opt/sgi/snmpagents/etc/uv.conf file for use by agent itself. A template file /opt/sgi/snmpagents/etc/uv.conf.template contains instructions on how to configure this file.

  4. Integrate agent configuration file.

    On RHEL, modify or create snmpd /etc/snmp/snmpd.options file and set the following environment variable:

    # Add SGI agent configurations
    OPTIONS="${OPTIONS} -c /opt/sgi/snmpagents/etc/snmpd.local.conf"

    On SLES, a properly substituted /opt/sgi/snmpagents/etc/snmpd.uv.conf file should be appended to the /etc/snmp/snmpd.local.conf file.