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( ... );
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.
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.
Same as reader_for but uses the read-write community strings from the application configuration file.
To install App::Netdisco, copy and paste the appropriate command in to your terminal.
perl -MCPAN -e shell
For more information on module installation, please visit the detailed CPAN module installation guide.