-
-
17 May 2022 21:06:21 UTC
- Distribution: App-Netdisco
- Source (raw)
- Browse (raw)
- Changes
- Homepage
- How to Contribute
- Repository
- Issues (20)
- Testers
- Kwalitee
Bus factor: 1- 74.63% Coverage
- License: bsd
- Activity
24 month- Tools
- Download (4.29MB)
- MetaCPAN Explorer
- Permissions
- Subscribe to distribution
- Permalinks
- This version
- Latest version
- Dependencies
- Algorithm::Cron
- AnyEvent
- AnyEvent::DNS::EtcHosts
- App::cpanminus
- App::local::lib::helper
- Archive::Extract
- Authen::Radius
- Authen::TacacsPlus
- CGI::Expand
- Command::Runner
- DBD::Pg
- DBIx::Class
- DBIx::Class::Helpers
- Daemon::Control
- Dancer
- Dancer::Plugin::Auth::Extensible
- Dancer::Plugin::DBIC
- Dancer::Plugin::Passphrase
- Dancer::Plugin::Swagger
- Dancer::Session::Cookie
- Data::Printer
- Data::Visitor::Tiny
- EV
- Expect
- File::Path
- File::ShareDir
- File::Slurper
- File::Spec::Functions
- Guard
- HTML::Parser
- HTTP::Tiny
- IO::Socket::INET6
- IO::Socket::SSL
- JSON
- JSON::PP
- JSON::XS
- List::MoreUtils
- List::Util
- MCE
- MIME::Base64
- Module::Load
- Moo
- Net::DNS
- Net::Domain
- Net::LDAP
- Net::OpenSSH
- NetAddr::IP
- NetAddr::MAC
- Opcode
- Package::DeprecationManager
- Path::Class
- Plack
- Plack::Handler::Twiggy
- Plack::Middleware::Debug
- Plack::Middleware::Expires
- Plack::Middleware::Headers
- Plack::Middleware::ReverseProxy
- Pod::Usage
- Regexp::Common
- Role::Tiny
- SNMP::Info
- SQL::Abstract
- SQL::Translator
- Scope::Guard
- Sereal
- Session::Storage::Secure
- Socket6
- Starman
- Storable
- Sub::Util
- Sys::SigAction
- Template
- Template::AutoFilter
- Template::Plugin::CSV
- Template::Plugin::Number::Format
- Term::ReadLine
- Term::UI
- Try::Tiny
- URI
- URI::Based
- URL::Encode
- URL::Encode::XS
- YAML
- YAML::XS
- aliased
- autovivification
- namespace::clean
- version
- and possibly others
- Reverse dependencies
- CPAN Testers List
- Dependency graph
NAME
App::Netdisco::Transport::SNMP
DESCRIPTION
Singleton for SNMP connections. Returns cached SNMP::Info instance for a given device IP, or else undef. All methods are class methods, for example:
my $snmp = App::Netdisco::Transport::SNMP->reader_for( ... );
reader_for( $ip, $useclass? )
Given an IP address, returns an SNMP::Info instance configured for and connected to that device. The IP can be any on the device, and the management interface will be connected to.
If the device is known to Netdisco and there is a cached SNMP community string, that community will be tried first, and then other community strings from the application configuration will be tried.
If
$useclass
is provided, it will be used as the SNMP::Info device class instead of the class in the Netdisco database.Returns
undef
if the connection fails.test_connection( $ip )
Similar to
reader_for
but will use the literal IP address passed, and does not support specifying the device class. The purpose is to test the SNMP connectivity to the device before a renumber.Attempts to have no side effect, however there will be a stored SNMP authentication hint (tag) in the database if the connection is successful.
Returns
undef
if the connection fails.writer_for( $ip, $useclass? )
Same as
reader_for
but uses the read-write community strings from the application configuration file.Returns
undef
if the connection fails.Module Install Instructions
To install App::Netdisco, copy and paste the appropriate command in to your terminal.
cpanm App::Netdisco
perl -MCPAN -e shell install App::Netdisco
For more information on module installation, please visit the detailed CPAN module installation guide.