Gathering statistics from servers

Abstract

Some notes on using lm_sensors, snmp and nrg/rrdtool on gathering stats from Linux (and other) servers.


Table of Contents
Overview
The lm_sensors package
SNMP
Using NRG to gather stats

Overview

Motherboards these days usually come with some sensors which can log basic temp/voltage and other data, the lm_sensors package allows linux to drop this information and some basic information about other hardware (e.g. how many and what kind of DIMMS are installed) into /proc. This data is then accessible either though commands on the pc or via snmp using a script to extend the snmp agent. Using something like MRTG,NRG or rrdtool it's fairly easy to chart this data over time (or we could just log it).

If we are using snmp then it would also be possible to use the trap machanism to raise alarms when systems ran over temperature or out of disk space etc.