Menu

#4716 moncfg snmpmon configures the wrong file in RHEL7.1

2.10
closed
Ling
None
unknown
5
2015-07-15
2015-06-26
No

we attempted to configure and start snmpmon on RHEL7.1 running on a PPC64 architecture machine.

This resulted in seeing the following message in /var/log/messages when an snmp trap was received.

Jun 25 11:49:49 dccxcat snmptrapd[78729]: No access configuration - dropping trap.

the snmptrapd daemon that comes with the RHEL7.1 distro comes from the net-snmp-5.7.2-20.el7.ppc64 package. and according to its documentation it reads its configuration from /etc/snmp/snmptrapd.conf.

after running monadd snmpmon; moncfg snmpmon. The contents of the /etc/snmp/snmptrapd.conf file is unchanged.

[root@dccxcat mibs]# cat /etc/snmp/snmptrapd.conf
# Example configuration file for snmptrapd
#
# No traps are handled by default, you must edit this file!
#
# authCommunity   log,execute,net public
# traphandle SNMPv2-MIB::coldStart    /usr/bin/bin/my_great_script cold

Looking at the code for the xcat plugin snmpmon.pm we see the following code:

my $confdir;
if(xCAT::Utils->isAIX()){
  $::snmpconfdir = "/opt/freeware/etc";
} else {
  $::snmpconfdir = "/usr/share/snmp";
}

And we do see that a file /usr/share/snmp/snmptrapd.conf has been created. However, for this distribution, this appears to be in the wrong place.

We are currently running the following version of xcat:

[root@dccxcat mibs]# lsxcatd  -v
Version 2.10 (git commit 22b5c8fd793ca32bb75f76899e1d27bd203a53c6, built Wed May 27 11:50:52 EDT 2015)

Discussion

  • Ling

    Ling - 2015-06-26
    • assigned_to: Ling
     
  • Ling

    Ling - 2015-06-26

    Checked in new revision 7423026878cc6cfc6bfb71810dbaa35d3129a535 to look for new config file location for snmpmon.

    if(xCAT::Utils->isAIX()){
    $::snmpconfdir = "/opt/freeware/etc";
    } else {
    if (-f "/etc/snmp/snmpd.conf") {
    $::snmpconfdir = "/etc/snmp";
    } else {
    $::snmpconfdir = "/usr/share/snmp";
    }
    }

     
  • Ling

    Ling - 2015-06-26
    • status: open --> pending
     
  • Ling

    Ling - 2015-06-26
    if(xCAT::Utils->isAIX()){
      $::snmpconfdir = "/opt/freeware/etc";
    } else {
        if (-f "/etc/snmp/snmpd.conf") {
            $::snmpconfdir = "/etc/snmp";
        } else {
            $::snmpconfdir = "/usr/share/snmp";
        }
    }
    
     
  • Ling

    Ling - 2015-07-15
    • status: pending --> closed
     
  • ralph bellofatto

    I am out of the office until 07/20/2015.

    I will respond to your message when I return.

    Note: This is an automated response to your message "[xcat:bugs] #4716
    moncfg snmpmon configures the wrong file in RHEL7.1" sent on 07/15/2015
    10:20:40 AM.

    This is the only notification you will receive while this person is away.

     
Auth0 Logo