Difference between revisions of "SNMPD"

From Nuclear Physics Group Documentation Pages
Jump to navigationJump to search
 
 
(One intermediate revision by one other user not shown)
Line 1: Line 1:
= SNMPD =
+
SNMPD is a simple transport model for sending data (and possibly commands) between different system. The [[[Cacti]] system uses it to get information from the various devices, including the "Sensorhawk".
  
 +
== Installing ==
  
Real useful, hard to understand the details.
+
yum installl net-snmp
 +
 
 +
This will also get lm-sensors if it wasn't already installed. You would probably want to configure it up, which is in /etc/snmp/. On einstein (and others) there is a perl script there in an attempt to create something that can pull more info from snmp. This is work in progress.
 +
 
 +
You also want some of the tools, including snmpwalk with:
 +
 
 +
yum install net-snmp-utils
 +
 
 +
== Testing ==
 +
 
 +
You can get info from snmp with the command "snmpget", but in general "snmpwalk" is easier. It allows you to walk through the tree of available snmp information and thus get a full view of the system.
 +
 
 +
To test the public space:
 +
  snmpwalk -v 1 -c public localhost .1
 +
 
 +
To test the NPG information:
 +
  snmpwalk -v 1 -c NPG localhost .1
 +
 
 +
To see if you can access from a different system, log into that system:
 +
  snmpwalk -v 1 -c NPG einstein.farm.physics.unh.edu .1
 +
  
 
== Access control and config ==
 
== Access control and config ==
  
See /etc/snmpd/snmpd.conf. This is where you allow/restrict access and can control what is presented. If only you could figure out the file.
+
See /etc/snmp/snmpd.conf. This is where you allow/restrict access and can control what is presented. If only you could figure out the file.
  
 
== Log Level control ==
 
== Log Level control ==
Line 14: Line 35:
 
The actual file to change is /etc/sysconfig/snmpd.options or /etc/snmpd/snmpd.options where the line
 
The actual file to change is /etc/sysconfig/snmpd.options or /etc/snmpd/snmpd.options where the line
 
  OPTIONS="-LS 0-4 d -Lf /dev/null -p /var/run/snmpd.pid -a"
 
  OPTIONS="-LS 0-4 d -Lf /dev/null -p /var/run/snmpd.pid -a"
 +
 +
On Einstein: 
 +
  OPTIONS="-LF0-3 /var/log/snmpd.log  -p /var/run/snmpd.pid -a"
 
has the necessary magic. See /etc/init.d/snmpd for the defailt.
 
has the necessary magic. See /etc/init.d/snmpd for the defailt.

Latest revision as of 18:45, 26 October 2009

SNMPD is a simple transport model for sending data (and possibly commands) between different system. The [[[Cacti]] system uses it to get information from the various devices, including the "Sensorhawk".

Installing

yum installl net-snmp

This will also get lm-sensors if it wasn't already installed. You would probably want to configure it up, which is in /etc/snmp/. On einstein (and others) there is a perl script there in an attempt to create something that can pull more info from snmp. This is work in progress.

You also want some of the tools, including snmpwalk with:

yum install net-snmp-utils

Testing

You can get info from snmp with the command "snmpget", but in general "snmpwalk" is easier. It allows you to walk through the tree of available snmp information and thus get a full view of the system.

To test the public space:

 snmpwalk -v 1 -c public localhost .1

To test the NPG information:

 snmpwalk -v 1 -c NPG localhost .1

To see if you can access from a different system, log into that system:

 snmpwalk -v 1 -c NPG einstein.farm.physics.unh.edu .1

Access control and config

See /etc/snmp/snmpd.conf. This is where you allow/restrict access and can control what is presented. If only you could figure out the file.

Log Level control

Logging is controlled on the command line, see the logging options in snmpcmd man page The actual file to change is /etc/sysconfig/snmpd.options or /etc/snmpd/snmpd.options where the line

OPTIONS="-LS 0-4 d -Lf /dev/null -p /var/run/snmpd.pid -a"

On Einstein:

 OPTIONS="-LF0-3 /var/log/snmpd.log  -p /var/run/snmpd.pid -a"

has the necessary magic. See /etc/init.d/snmpd for the defailt.