SNMP: Difference between revisions

From CSCWiki
Jump to navigation Jump to search
m (Edited to reflect reality. :P)
(Start documenting SNMP for UPS)
Line 1: Line 1:
= UPS =
The Computer Science Club runs Net-SNMP on all of our host machines. This provides real-time data on network, cpu and disk load, as well as memory usage. We also record temperature and fan speed data for capable hosts. On caffeine, we record apache and postfix statistics.


We can monitor two of our UPSs via SNMP [[Machine_List|#UPS]]:
Update: SNMP is annoying and complicated and has been removed almost everywhere. Mirror still runs it however.


== Debian Setup ==
If you want to enable sensors:
* sudo apt-get install lm-sensors
* sudo sensors-detect
* sudo modprobe the recommended modules and them to /etc/modules as needed; run sensors to verify that correct modules are loaded and working
* sudo invoke-rc.d snmpd restart


Install snmp and snmp-mibs-downloader (note: snmp-mibs-downloader is not available in stretch repository, so just download the deb from sid).
[[Category:Software]]

Download https://nagios.cscf.uwaterloo.ca/kiosk/powernet416.mib and place it in /usr/share/snmp/mibs

== Getting Status ==

snmpget -v 1 -c MSO mc-3015-h7-ups-1.cs.uwaterloo.ca PowerNet-MIB::upsBasicOutputStatus.0

This will return something like:

PowerNet-MIB::upsBasicOutputStatus.0 = INTEGER: onLine(2)

Revision as of 13:18, 16 December 2015

UPS

We can monitor two of our UPSs via SNMP #UPS:

Debian Setup

Install snmp and snmp-mibs-downloader (note: snmp-mibs-downloader is not available in stretch repository, so just download the deb from sid).

Download https://nagios.cscf.uwaterloo.ca/kiosk/powernet416.mib and place it in /usr/share/snmp/mibs

Getting Status

   snmpget -v 1 -c MSO mc-3015-h7-ups-1.cs.uwaterloo.ca PowerNet-MIB::upsBasicOutputStatus.0

This will return something like:

   PowerNet-MIB::upsBasicOutputStatus.0 = INTEGER: onLine(2)