Sun Microsystems, Inc.  Oracle System Handbook - ISO 7.0 May 2018 Internal/Partner Edition
   Home | Current Systems | Former STK Products | EOL Systems | Components | General Info | Search | Feedback

Asset ID: 1-71-1519018.1
Update Date:2017-06-26
Keywords:

Solution Type  Technical Instruction Sure

Solution  1519018.1 :   How to Install and Configure SNMP Traps and Log the Traps onto a Log File  


Related Items
  • Oracle Fabric Interconnect F1-15
  •  
  • Oracle Fabric Interconnect F1-4
  •  
Related Categories
  • PLA-Support>Sun Systems>SAND>Network>SN-SND: Oracle Virtual Networking
  •  




In this Document
Goal
Solution


Applies to:

Oracle Fabric Interconnect F1-15 - Version All Versions and later
Oracle Fabric Interconnect F1-4 - Version All Versions and later
Information in this document applies to any platform.
Checked for relevance on 06/26/2014

Goal

Install and Configure SNMP Traps and Log the Traps onto a Log File

Solution

On Oracle Fabric Interconnect Chassis:

add snmp trap-dest <ip:port> -community=###### -version=SNMPv2 | SNMPv3

EX: add snmp trap-dest 192.168.9.137:162 –community=public –version=SNMPv2

 
The above command forwards the traps from the Chassis to the destination IP .

show snmp

 Execute the above command to see the trap destinations added.


On Server:

Setup snmptrapd on the server referenced by the specified IP address.  Please note snmptrapd needs to be listening on the specified port as well.

Operating System: - Red Hat Enterprise Linux Server release 5.5 (Tikanga) and all version.

SNMP Package
net-snmp-5.3.2.2-9.el5.rpm (rpm –ivh net-snmp-<version>.el5.rpm)
net-snmp-utils-5.3.2.2-9.el5.rpm (rpm –ivh net-snmp-utils-<version>.el5.rpm)
net-snmp-libs-5.3.2.2-9.el5.rpm (rpm –ivh net-snmp-libs-5.<version>.el5.rpm)

Note: - Before installing the above packages the server should have m_senors-2.10 <version>.rpm dependent package.

 
Install net-snmp-utils (a third party tool) from the available binaries or download the source, compile and install snmputils on the server.

For RedHat or Oracle Linux v6.X, the easiest way to install the NET-SNMP* packages are through yum.

# yum search snmp
# yum install net-snmp*

The NET-SNMP* packages should be readily available from the public_ol6_latest repository.

Once the above is installed, find the snmptrapd.conf file and add this authcommunity log,execute,net public into it or you can use disableAuthorization yes ; either one of them.



If snmptrapd.conf is not found on the server then configure it using snmpconf command, using the below process:

You can create snmpd.conf, snmptrapd.conf or snmp.conf.

###########################################################################
#
# snmptrapd.conf
#
# - created by the snmpconf configuration program
#
###########################################################################
# SECTION: Logging options
#
# Logging options

# logoption: Set options controlling where to log to
# See -L options in the snmptrapd.conf man page

# logoption f /var/log/snmp/snmptrad_out.log

# outputoption: Toggle options controlling output display
# See -O options in the snmptrapd.conf man page

#disableAuthorization yes

authcommunity log,execute,net public

 
----------------------------------------------------------------------------------
Execute the following on the server.

 

mkdir /var/log/snmp – Create this directory to dump snmptrad_out.log file.

Copy MIBS to /usr/share/snmp/mibs/ (from the chassis to Server)

Chassis MIBS path: - /opt/xsigo/xsigos/<version>/mibs to /usr/share/snmp/mibs/

 

#vi /etc/sysconfig/snmptrapd.options
# snmptrapd command line options
# OPTIONS="-Lsd -p /var/run/snmptrapd.pid"
#SNMP_LOGFILE_OPTION="-L f /var/log/messages"
SNMP_LOGFILE_OPTION="-L f /var/log/snmp/snmptrad_out.log" – (We are specifying snmp output in log file location /var/log/snmp/snmptrad_out.log)
SNMP_FORMAT_OPTION=""
OPTIONS="-A -m ALL -p /var/run/snmptrapd.pid $SNMP_LOGFILE_OPTION $SNMP_FORMAT_OPTION"

Set the run level on snmptrapd: - This will run snmptrapd in below run levels for linux run level 5 is default.
chkconfig --level 3 snmptrapd on
chkconfig --level 4 snmptrapd on
chkconfig --level 5 snmptrapd on

To confirm chkconfig run levels
chkconfig --list | grep snmptrapd

To Start the snmptrapd
# service snmptrapd stop
# service snmptrapd start

 
The traps should be found in /var/log/snmp/snmptrad_out.log (tail –f in /var/log/snmp/snmptrad_out.log).


Attachments
This solution has no attachment
  Copyright © 2018 Oracle, Inc.  All rights reserved.
 Feedback