NAME
Net::SNMP::Mixin::System - mixin class for the mib-2 system-group values
VERSION
Version 0.03
SYNOPSIS
A Net::SNMP mixin class for mib-II system-group info. It's just in the distribution to act as a blueprint for mixin authors.
use Net::SNMP;
use Net::SNMP::Mixin qw/mixer init_mixins/;
my $session = Net::SNMP->session( -hostname => 'foo.bar.com' );
$session->mixer('Net::SNMP::Mixin::System');
$session->init_mixins;
snmp_dispatcher() if $session->nonblocking;
die $session->error if $session->error;
my $system_group = $session->get_system_group;
printf "Name: %s, Contact: %s, Location: %s\n",
$system_group->{sysName},
$system_group->{sysContact},
$system_group->{sysLocation};
MIXIN METHODS
OBJ->get_system_group()
Returns the mib-II system-group as a hash reference:
{
sysDescr => DisplayString,
sysObjectID => OBJECT_IDENTIFIER,
sysUpTime => TimeTicks,
sysContact => DisplayString,
sysName => DisplayString,
sysLocation => DisplayString,
sysServices => INTEGER,
}
INITIALIZATION
OBJ->_init($reload)
Fetch the SNMP mib-II system-group values from the host. Don't call this method direct!
PRIVATE METHODS
Only for developers or maintainers.
_fetch_system_group($session)
Fetch values from the system-group once during object initialization.
_system_group_cb($session)
The callback for _fetch_system_group.
BUGS
Please report any bugs or feature requests to bug-net-snmp-mixin-system at rt.cpan.org
, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Net-SNMP-Mixin. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
SUPPORT
You can find documentation for this module with the perldoc command.
perldoc Net::SNMP::Mixin::System
You can also look for information at:
AnnoCPAN: Annotated CPAN documentation
CPAN Ratings
RT: CPAN's request tracker
Search CPAN
COPYRIGHT & LICENSE
Copyright 2008 Karl Gaissmaier, all rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.