diff options
Diffstat (limited to 'share/snmp')
-rw-r--r-- | share/snmp/Makefile | 11 | ||||
-rw-r--r-- | share/snmp/OPENBSD-BASE-MIB.txt | 59 | ||||
-rw-r--r-- | share/snmp/OPENBSD-MEM-MIB.txt | 107 | ||||
-rw-r--r-- | share/snmp/OPENBSD-SENSORS-MIB.txt | 174 | ||||
-rw-r--r-- | share/snmp/OPENBSD-SNMPD-CONF.txt | 73 |
5 files changed, 424 insertions, 0 deletions
diff --git a/share/snmp/Makefile b/share/snmp/Makefile new file mode 100644 index 00000000000..c2a33761c14 --- /dev/null +++ b/share/snmp/Makefile @@ -0,0 +1,11 @@ +# $OpenBSD: Makefile,v 1.1 2008/12/23 18:32:10 reyk Exp $ + +FILES= OPENBSD-SNMPD-CONF.txt OPENBSD-BASE-MIB.txt +FILES+= OPENBSD-MEM-MIB.txt OPENBSD-SENSORS-MIB.txt + +all clean cleandir depend lint obj tags: _SUBDIRUSE + +realinstall: + ${INSTALL} -c -m 0444 ${FILES} ${DESTDIR}${BINDIR}/snmp/mibs + +.include <bsd.prog.mk> diff --git a/share/snmp/OPENBSD-BASE-MIB.txt b/share/snmp/OPENBSD-BASE-MIB.txt new file mode 100644 index 00000000000..2a2666954a1 --- /dev/null +++ b/share/snmp/OPENBSD-BASE-MIB.txt @@ -0,0 +1,59 @@ +-- $OpenBSD: OPENBSD-BASE-MIB.txt,v 1.1 2008/12/23 18:32:10 reyk Exp $ +-- +-- Copyright (c) 2008 Reyk Floeter <reyk@openbsd.org> +-- Copyright (c) 2004-2007 Joel Knight <enabled@myrealbox.com> +-- +-- Permission to use, copy, modify, and distribute this document for any +-- purpose with or without fee is hereby granted, provided that the above +-- copyright notice and this permission notice appear in all copies. +-- +-- THE DOCUMENT IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +-- WITH REGARD TO THIS DOCUMENT INCLUDING ALL IMPLIED WARRANTIES OF +-- MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +-- ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +-- WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +-- ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +-- OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS DOCUMENT. + +OPENBSD-BASE-MIB DEFINITIONS ::= BEGIN + +IMPORTS + MODULE-IDENTITY, NOTIFICATION-TYPE, OBJECT-TYPE, enterprises + FROM SNMPv2-SMI + MODULE-COMPLIANCE, OBJECT-GROUP + FROM SNMPv2-CONF; + +openBSD MODULE-IDENTITY + LAST-UPDATED "200612100000Z" + ORGANIZATION "OpenBSD" + CONTACT-INFO + "Editor: Reyk Floeter + EMail: reyk@openbsd.org + WWW: http://www.openbsd.org/ + + Editor: Joel Knight + EMail: enabled@myrealbox.com + WWW: http://www.packetmischief.ca/openbsd/snmp/" + DESCRIPTION + "The base MIB module for the OpenBSD project." + REVISION "200812230000Z" + DESCRIPTION + "Updated for MIB for the OpenBSD snmpd(8) implementation." + ::= { enterprises 30155 } + +-- +-- OpenBSD sub-MIBs +-- + +-- pfMIBObjects OBJECT IDENTIFIER ::= { openBSD 1 } +sensorsMIBObjects OBJECT IDENTIFIER ::= { openBSD 2 } +-- carpMIBObjects OBJECT IDENTIFIER ::= { openBSD 3 } +-- ipsecMIBObjects OBJECT IDENTIFIER ::= { openBSD 4 } +memMIBObjects OBJECT IDENTIFIER ::= { openBSD 5 } + +-- Other values +localSystem OBJECT IDENTIFIER ::= { openBSD 23 } +openBSDDefaultObjectID OBJECT IDENTIFIER ::= { localSystem 1 } +localTest OBJECT IDENTIFIER ::= { openBSD 42 } + +END diff --git a/share/snmp/OPENBSD-MEM-MIB.txt b/share/snmp/OPENBSD-MEM-MIB.txt new file mode 100644 index 00000000000..adfb181ec67 --- /dev/null +++ b/share/snmp/OPENBSD-MEM-MIB.txt @@ -0,0 +1,107 @@ +-- $OpenBSD: OPENBSD-MEM-MIB.txt,v 1.1 2008/12/23 18:32:10 reyk Exp $ +-- +-- Copyright (c) 2008 Reyk Floeter <reyk@openbsd.org> +-- +-- Permission to use, copy, modify, and distribute this document for any +-- purpose with or without fee is hereby granted, provided that the above +-- copyright notice and this permission notice appear in all copies. +-- +-- THE DOCUMENT IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +-- WITH REGARD TO THIS DOCUMENT INCLUDING ALL IMPLIED WARRANTIES OF +-- MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +-- ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +-- WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +-- ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +-- OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS DOCUMENT. + +OPENBSD-MEM-MIB DEFINITIONS ::= BEGIN + +IMPORTS + MODULE-IDENTITY, NOTIFICATION-TYPE, OBJECT-TYPE, Counter64 + FROM SNMPv2-SMI + DisplayString + FROM SNMPv2-TC + ifIndex, ifNumber + FROM IF-MIB + openBSD + FROM OPENBSD-BASE-MIB + MODULE-COMPLIANCE, OBJECT-GROUP + FROM SNMPv2-CONF; + +memMIBObjects MODULE-IDENTITY + LAST-UPDATED "200812230000Z" + ORGANIZATION "OpenBSD" + CONTACT-INFO + "Editor: Reyk Floeter + EMail: reyk@openbsd.org + WWW: http://www.openbsd.org/" + DESCRIPTION + "The MIB module exporting OpenBSD memory statistics." + ::= { openBSD 5 } + +-- +-- Core MIB elements +-- + +-- memMIBVersion OBJECT IDENTIFIER ::= { memMIBObjects 1 } +memIfTable OBJECT IDENTIFIER ::= { memMIBObjects 2 } + +-- +-- MIB details +-- + +memMIBVersion OBJECT-TYPE + SYNTAX Integer32 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The current version of this MIB supported by the agent. + The memory MIB might be updated frequently to export + statistics specific to the latest version of OpenBSD. + The client should check this version." + ::= { memMIBObjects 1 } + +memIfTable OBJECT-TYPE + SYNTAX SEQUENCE OF memIfEntry + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "A list of interface entries. The number of entries is given + by the value of ifNumber." + ::= { memMIBObjects 2 } + +memIfEntry OBJECT-TYPE + SYNTAX memIfEntry + MAX-ACCESS not-accessible + STATUS current + DESCRIPTION + "An entry containing memory and systems statistics applicable + to a particular interface." + INDEX { ifIndex } + ::= { memIfTable 1 } + +memIfEntry ::= SEQUENCE { + memIfName DisplayString, + memIfLiveLocks Counter64 +} + +memIfName OBJECT-TYPE + SYNTAX DisplayString + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The textual name of the interface as assigned by the operating + system. For example, `lo0' for the first loopback device or + `em1' for the second Ethernet device using the `em' driver." + ::= { memIfEntry 1 } + +memIfLiveLocks OBJECT-TYPE + SYNTAX Counter64 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The number of times the growth of the interface receive ring + was limited as a response to high system load." + ::= { memIfEntry 2 } + +END diff --git a/share/snmp/OPENBSD-SENSORS-MIB.txt b/share/snmp/OPENBSD-SENSORS-MIB.txt new file mode 100644 index 00000000000..d82f7689c63 --- /dev/null +++ b/share/snmp/OPENBSD-SENSORS-MIB.txt @@ -0,0 +1,174 @@ +-- $OpenBSD: OPENBSD-SENSORS-MIB.txt,v 1.1 2008/12/23 18:32:10 reyk Exp $ +-- +-- Copyright (c) 2006-2007 Joel Knight <enabled@myrealbox.com> +-- +-- Permission to use, copy, modify, and distribute this document for any +-- purpose with or without fee is hereby granted, provided that the above +-- copyright notice and this permission notice appear in all copies. +-- +-- THE DOCUMENT IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +-- WITH REGARD TO THIS DOCUMENT INCLUDING ALL IMPLIED WARRANTIES OF +-- MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +-- ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +-- WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +-- ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +-- OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS DOCUMENT. + +OPENBSD-SENSORS-MIB DEFINITIONS ::= BEGIN + +IMPORTS + MODULE-IDENTITY, NOTIFICATION-TYPE, OBJECT-TYPE, + Integer32, Unsigned32, TimeTicks, enterprises + FROM SNMPv2-SMI + openBSD + FROM OPENBSD-BASE-MIB + MODULE-COMPLIANCE, OBJECT-GROUP + FROM SNMPv2-CONF; + +sensorsMIBObjects MODULE-IDENTITY + LAST-UPDATED "200612100000Z" + ORGANIZATION "OpenBSD" + CONTACT-INFO + "Editor: Reyk Floeter + EMail: reyk@openbsd.org + WWW: http://www.openbsd.org/ + + Editor: Joel Knight + EMail: enabled@myrealbox.com + WWW: http://www.packetmischief.ca/openbsd/snmp/" + DESCRIPTION + "The MIB module for gathering information from + OpenBSD's kernel sensor framework." + REVISION "200812230000Z" + DESCRIPTION + "Updated for MIB for the OpenBSD snmpd(8) implementation." + ::= { openBSD 2 } + +-- +-- Define the sections of the MIB +-- + +sensors OBJECT IDENTIFIER ::= { sensorsMIBObjects 1 } + +-- +-- MIB definitions +-- + +sensorNumber OBJECT-TYPE + SYNTAX Integer32 + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The number of sensors present on this system." + ::= { sensors 1 } + +sensorTable OBJECT-TYPE + SYNTAX SEQUENCE OF SensorEntry + MAX-ACCESS not-accessible + STATUS current + DESCRIPTION + "A list of individual sensors. The number of entries is + given by the value of sensorNumber." + ::= { sensors 2 } + +sensorEntry OBJECT-TYPE + SYNTAX SensorEntry + MAX-ACCESS not-accessible + STATUS current + DESCRIPTION + "An entry containing management information applicable to a + particular sensor." + INDEX { sensorIndex } + ::= { sensorTable 1 } + +SensorEntry ::= SEQUENCE { + sensorIndex Integer32, + sensorDescr OCTET STRING, + sensorType INTEGER, + sensorDevice OCTET STRING, + sensorValue OCTET STRING, + sensorUnits OCTET STRING, + sensorStatus INTEGER +} + +sensorIndex OBJECT-TYPE + SYNTAX Integer32 (1..2147483647) + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "A unique value, greater than zero, for each sensor." + ::= { sensorEntry 1 } + +sensorDescr OBJECT-TYPE + SYNTAX OCTET STRING + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "A description of the sensor indicating what information the + sensor is monitoring." + ::= { sensorEntry 2 } + +sensorType OBJECT-TYPE + SYNTAX INTEGER { + temperature(0), + fan(1), + voltsdc(2), + voltsac(3), + resistance(4), + power(5), + current(6), + watthour(7), + amphour(8), + indicator(9), + raw(10), + percent(11), + illuminance(12), + drive(13), + timedelta(14) + } + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "Indicates the type of sensor." + ::= { sensorEntry 3 } + +sensorDevice OBJECT-TYPE + SYNTAX OCTET STRING + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The name of the sensor driver that provides the sensor." + ::= { sensorEntry 4 } + +sensorValue OBJECT-TYPE + SYNTAX OCTET STRING + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The value the sensor is currently reporting." + ::= { sensorEntry 5 } + +sensorUnits OBJECT-TYPE + SYNTAX OCTET STRING + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "The units that the sensor reports in." + ::= { sensorEntry 6 } + +sensorStatus OBJECT-TYPE + SYNTAX INTEGER { + unspecified(0), + ok(1), + warn(2), + critical(3), + unknown(4) + } + MAX-ACCESS read-only + STATUS current + DESCRIPTION + "Indicates whether the sensor value is within an acceptable + range." + ::= { sensorEntry 7 } + +END diff --git a/share/snmp/OPENBSD-SNMPD-CONF.txt b/share/snmp/OPENBSD-SNMPD-CONF.txt new file mode 100644 index 00000000000..0efc32faa72 --- /dev/null +++ b/share/snmp/OPENBSD-SNMPD-CONF.txt @@ -0,0 +1,73 @@ +-- $OpenBSD: OPENBSD-SNMPD-CONF.txt,v 1.1 2008/12/23 18:32:10 reyk Exp $ +-- +-- Copyright (c) 2008 Reyk Floeter <reyk@openbsd.org> +-- +-- Permission to use, copy, modify, and distribute this document for any +-- purpose with or without fee is hereby granted, provided that the above +-- copyright notice and this permission notice appear in all copies. +-- +-- THE DOCUMENT IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +-- WITH REGARD TO THIS DOCUMENT INCLUDING ALL IMPLIED WARRANTIES OF +-- MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +-- ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +-- WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +-- ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +-- OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS DOCUMENT. + +OPENBSD-SNMPD-CONF DEFINITIONS ::= BEGIN + +-- +-- This file lists all the MIBs that OpenBSD snmpd(8) implements at +-- present. Non-OpenBSD MIB files are not included in this distribution. +-- + +IMPORTS + -- Management Information Base (MIB) for the Simple Network + -- Management Protocol (SNMPv2), RFC 3418, December 2002 + snmpMIB + FROM SNMPv2-MIB + + -- IANA ifTypes MIB, http://www.iana.org/assignments/ianaiftype-mib + ianaifType + FROM IANAifType-MIB + + -- The Interface Group MIB, RFC 2863, June 2000 + ifMIB + FROM IF-MIB + + -- Definitions of Managed Objects for Bridges, RFC 4188, + -- September 2005 + dot1dBridge + FROM BRIDGE-MIB + + -- Textual Conventions for Internet Network Addresses, + -- RFC 4001, February 2005 + inetAddressMIB + FROM INET-ADDRESS-MIB + + -- Management Information Base for the Internet Protocol + -- (IP), RFC 4293, April 2006 + ipMIB + FROM IP-MIB + + -- Host Resources MIB, RFC 2790, March 2000 + hostResourcesMibModule + FROM HOST-RESOURCES-MIB + + -- + -- OpenBSD-specific MIBs + -- + + -- Base MIB, OPENBSD-BASE-MIB.txt, OpenBSD 4.3 + openBSD + FROM OPENBSD-BASE-MIB + + -- Kernel sensors MIB, OPENBSD-SENSORS-MIB.txt, OpenBSD 4.3 + sensorsMIBObjects + FROM OPENBSD-SENSORS-MIB + + -- Memory statistics MIB, OPENBSD-MEM-MIB.txt, OpenBSD 4.5 + memMIBObjects + FROM OPENBSD-MEM-MIB; + +END |