Subject: Diskspace monitoring using SNMP

From: "Scott Hiemstra" <[email-masked]>
Date: Tue, 22 Jul 2008 07:12:45 -0400

I've looked through the sample configs and the disk monitoring contrib files
but I'm looking for something a little more streamlined that doesn't require
me to connect to 30 servers and drop in a snippet or require df.  I already
use the "disk /usr" convention in my snmpd.conf and Windows provides the
information right out of the box.  I think my problem is, I'm not sure how
to integrate the data I know how to get into the Argus config.  I'm running
Argus 3.5 if it matters.

Basically, I just want a notification sent if any disk on any system reaches
95% full.

Sample results (UNIX):
HOST-RESOURCES-MIB::hrStorageDescr.8 = STRING: /usr
HOST-RESOURCES-MIB::hrStorageAllocationUnits.8 = INTEGER: 2048 Bytes
HOST-RESOURCES-MIB::hrStorageSize.8 = INTEGER: 2477079
HOST-RESOURCES-MIB::hrStorageUsed.8 = INTEGER: 980715
HOST-RESOURCES-MIB::hrStorageAllocationFailures.8 = Counter32: 0

Sample results (Windows):
HOST-RESOURCES-MIB::hrStorageDescr.4 = STRING: G:\ Label:Webs  Serial Number
d0b02380
HOST-RESOURCES-MIB::hrStorageAllocationUnits.4 = INTEGER: 4096 Bytes
HOST-RESOURCES-MIB::hrStorageSize.4 = INTEGER: 138789543
HOST-RESOURCES-MIB::hrStorageUsed.4 = INTEGER: 5067355
HOST-RESOURCES-MIB::hrStorageAllocationFailures.4 = Counter32: 0

1.3.6.1.2.1.25.2.3.1 is the OID if needed, you will need the HOST-MIB for
NET/UCD SNMP installed.

Does anyone use this information for storage monitoring instead of the
snippet additions to snmpd.conf using df?  Do you have a config sample?

Thanks in advance,
Scott

---

From: Jeremy Kister <[email-masked]>
Date: Tue, 22 Jul 2008 09:50:36 -0400

> snippet additions to snmpd.conf using df?  Do you have a config sample?

because you want a percent, you'll have to either tell argus how big your 
disk is or else you can tell it to ask the server how big the disk is.

asking the server how big the disk is seems silly, as argus will have to 
keep asking and the answer will rarely change.

this should work - but not tested:

Group "machine" {
  hostname: machine.example.com
  Service UDP/SNMP {
    # data for behind the scenes
    hidden: yes
    oid: .1.3.6.1.2.1.25.2.3.1.6.2
    uname: disk_used_c
  }
  Service Compute {
    # n.b. the 10000000000, below, is total disk size in bytes
    expr: ( %{Top:Servers:machine:disk_used_c} / 10000000000 ) * 100
    gr_range: 0-100
    ylabel: percent used
    graph: yes
    label: disk usage on C:
    uname: disk_usage_c
    maxvalue: 90
    messagedn: disk usage percent at %v on %o{ip::hostname} C:
    messageup: disk usage better on %o{ip::hostname} C:
  }
}

-- 

Jeremy Kister
http://jeremy.kister.net./