SNMP

The Perl5 'SNMP' Extension Module for the Net-SNMP SNMP package.
Download

SNMP Ranking & Summary

Advertisement

  • Rating:
  • License:
  • Perl Artistic License
  • Price:
  • FREE
  • Publisher Name:
  • Wes Hardaker
  • Publisher web site:
  • http://search.cpan.org/~hardaker/

SNMP Tags


SNMP Description

The Perl5 'SNMP' Extension Module for the Net-SNMP SNMP package. SNMP is a Perl5 'SNMP' extension module for the Net-SNMP SNMP package.Note: The perl SNMP 5.0 module which comes with net-snmp 5.0 and higher is different than previous versions in a number of ways. Most importantly, it behaves like a proper net-snmp application and calls init_snmp properly, which means it will read configuration files and use those defaults where appropriate automatically parse MIB files, etc. This will likely affect your perl applications if you have, for instance, default values set up in your snmp.conf file (as the perl module will now make use of those defaults). The docmuentation, however, has sadly not been updated yet (aside from this note), nor is the read_config default usage implementation fully complete.The basic operations of the SNMP protocol are provided by this module through an object oriented interface for modularity and ease of use. The primary class is SNMP::Session which encapsulates the persistent aspects of a connection between the management application and the managed agent. Internally the class is implemented as a blessed hash reference. This class supplies 'get', 'getnext', 'set', 'fget', and 'fgetnext' method calls. The methods take a variety of input argument formats and support both syncronous and asyncronous operation through a polymorphic API (i.e., method behaviour varies dependent on args passed - see below).SYNOPSIS use SNMP; ... $sess = new SNMP::Session(DestHost => localhost, Community => public); $val = $sess->get('sysDescr.0'); ... $vars = new SNMP::VarList(, , ); @vals = $sess->get($vars); ... $vb = new SNMP::Varbind(); do { $val = $sess->getnext($vb); print "@{$vb} "; } until ($sess->{ErrorNum}); ... $SNMP::save_descriptions = 1; SNMP::initMib(); # assuming mib is not already loaded print "$SNMP::MIB{sysDescr}{description} "; Requirements: · Perl


SNMP Related Software