Everything Penguin, Inc.

Helping to support the open source community.
Search this Site:

Local Sources
  • /pub

  • Linux OS
  • /pub/OS/Linux

  • Networking
  • /pub/Networking

  • Network Services
  • /pub/NetworkServices

  • Clustering
  • HA
  • DRM

  • Encryption
  • Keytool/OpenSSL
  • Java Samples

  • Development
  • Design
  • C/C++
  • Java
  • Perl
  • Shell
  • Web / J2EE

  • Storage
  • Filesystems
  • HPC
  • /pub/Storage

  • Not Linux ?
  • BSD
  • HP-UX
  • Solaris
  • VM
  • Windows
  • /pub/OS

  • Security
  • /pub/Security
  •  Parent Directory

    SNMP Trap Server howto:
    Brett Lee
    =============================================================================
    
    
    
    - Download, build, and install net-snmp-5.x.x
    
        tar xvf net*; cd net*; ./configure; make; make test; make install
    
    
    
    - Verify the binaries exist:
    
        [root@linux build]# ls /usr/local/sbin
        snmpd  snmptrapd
        [root@linux local]# ls /usr/local/bin
        encode_keychange  snmpbulkget   snmpget      snmptable      snmpwalk
        fixproc           snmpbulkwalk  snmpgetnext  snmptest       tkmib
        ipf-mod.pl        snmpcheck     snmpinform   snmptranslate  traptoemail
        mib2c             snmpconf      snmpnetstat  snmptrap
        mib2c-update      snmpdelta     snmpset      snmpusm
        net-snmp-config   snmpdf        snmpstatus   snmpvacm
        [root@linux local]#
    
    
    
    - Create the configuration files.  The configuration files can have a couple
      possible names and locations - mine were in /usr/local/share/snmp/.
    
      If this is the initial installation of system, you may want to use the
      nice tool to generate them.  The tool will generate files in `pwd`, but
      if you pass it a '-i' option it will copy them to /usr/local/share/snmp/. 
    
      ========================================================================
      Usage is easy (just lots of options):
    
      [root@linux local]# /usr/local/bin/snmpconf
    
      I can create the following types of configuration files for you.
      Select the file type you wish to create:
      (you can create more than one as you run this program)
    
         1:  snmp.conf
         2:  snmptrapd.conf
         3:  snmpd.conf
    
      Other options: quit
    
      Select File:
      ========================================================================
    
    
    
    - To setup trapd, ensure that the following files exist:
    
      /usr/local/share/snmp/snmp.conf
        (example can be found in this web directory)
    
      /usr/local/share/snmp/snmptrapd.conf
        (example can be found in this web directory)
    
    
    - Fire up the listener:
    
      /usr/local/sbin/snmptrapd -A -d
    
    
    - If logging is configured, observe the log file:
    
        tail -f /var/log/snmptrapd.log
    
    
    - Test it out:
    
        For each type of access you have configured, run the appropriate command:
    
         - No Authentication, No Privacy:
         snmpinform -u <user> -l noAuthNoPriv <trapdserver> 42 coldStart.0
    
         - Authentication, No Privacy:
         snmpinform -u <user> -l authNoPriv -a MD5 -A <password> <trapdserver>
    
         - Authentication And Privacy:
         snmpinform -u <user> -l authPriv -a MD5 -A <authpassword> \
             -x DES -X <encryptpassword> <host> 42 coldStart.0
    
    
    - If all is successful, your trapd server is working.
    
    - Now you can setup your clients.
    
    
    - If not:
    
      1.  Modify the debugging settings in 'snmp.conf'.  The trapd server
          reads this file as well as 'snmptrapd.conf'.
    
      2.  Make sure you are reading your new config file:
             # pkill snmptrapd
             # /usr/local/sbin/snmptrapd -A -c /usr/local/share/snmp/snmptrapd.conf
             # tail -f /var/log/snmptrapd.log
    
    
    
    

    Other Sites

    RFC's
  • FAQ's
  • IETF
  • RFC Sourcebook

  • Linux
  • Linux- Intro
  • Bash - Intro
  • Bash - Advanced
  • Command Line
  • System Administration
  • Network Administration
  • Man Pages (& more)
  • More Guides
  • Red Hat Manuals
  • HOWTO's

  • Reference/Tutorials
  • C++ @ cppreference
  • C++ @ cplusplus
  • CSS @ echoecho
  • DNS @ Zytrax
  • HTML @ W3 Schools
  • Java @ Sun
  • LDAP @ Zytrax
  • Linux @ YoLinux
  • MySQL
  • NetFilter
  • Network Protocols
  • OpenLDAP
  • Quagga
  • Samba
  • Unix Programming


  • Sponsors:
  • BrettLee.com
  • TheFrontOffice.BIZ
  • ScubaNavigator.com
  • Nitrox.net

  • [ Statistics by AWStats ]

    [ Powered by Red Hat Linux ] [ Powered by Apache Server] [ Powered by MySQL ]

    In an effort to provide a service of value to the open source community, I've put together this website that containing many of my notes and references.

    This website is not authoritative and it is certainly not without errors; it is a work in progress.

    In addition to my contributions you will also find the work of others. Where the work is not mine, I have tried to indicate that, and to reference the source of the work: by citing the original author, retaining the authors' name and license wherever present, or by placing the work in a suitably named URL containg /external/ in the path. If you find any work here that should not be publically available, please send me a note and it will be removed.

    As for my contributions, you are free to use any of *MY* notes or code from this website unless specifically instructed otherwise.

    Brett Lee, Ph.D., President & CEO
    Everything Penguin, Inc.