← Back to team overview

nagios-charmers team mailing list archive

[Merge] ~andre-ruiz/charm-nagios/+git/charm-nagios-implement-traps:master into charm-nagios:master

 

Andre Ruiz has proposed merging ~andre-ruiz/charm-nagios/+git/charm-nagios-implement-traps:master into charm-nagios:master.

Commit message:
Implemented trap sending functionality.

Requested reviews:
  Nagios Charm developers (nagios-charmers)

For more details, see:
https://code.launchpad.net/~andre-ruiz/charm-nagios/+git/charm-nagios-implement-traps/+merge/386601

Implemented trap sending functionality.

I tested in a new cloud and it seems ok. Please let me know if you have any comments.
-- 
Your team Nagios Charm developers is requested to review the proposed merge of ~andre-ruiz/charm-nagios/+git/charm-nagios-implement-traps:master into charm-nagios:master.
diff --git a/config.yaml b/config.yaml
index e4755ad..5221c7a 100644
--- a/config.yaml
+++ b/config.yaml
@@ -284,3 +284,9 @@ options:
             Change this or add commands if you have custom notification plugins.
             Multiple notification commands should be separated by commas.
             All notification commands are executed when the contact needs to be notified.
+    send_traps_to:
+        default: ""
+        type: string
+        description: |
+            Defines the IP or Host Name to send snmp traps to. Leave blank (empty) to disable
+            the traps functionality.
diff --git a/files/mibs/NAGIOS-NOTIFY-MIB b/files/mibs/NAGIOS-NOTIFY-MIB
new file mode 100644
index 0000000..03b4c07
--- /dev/null
+++ b/files/mibs/NAGIOS-NOTIFY-MIB
@@ -0,0 +1,620 @@
+NAGIOS-NOTIFY-MIB DEFINITIONS ::= BEGIN
+  IMPORTS
+    MODULE-IDENTITY, OBJECT-TYPE,  NOTIFICATION-TYPE,
+    Integer32, Gauge32
+      FROM SNMPv2-SMI
+    nagios,NotifyType,HostStateID,HostStateType,ServiceStateID
+      FROM NAGIOS-ROOT-MIB;
+
+nagiosNotify MODULE-IDENTITY
+  LAST-UPDATED "200503090000Z" -- March 9, 2005
+  ORGANIZATION "Nagios"
+  CONTACT-INFO
+      " Subhendu Ghosh
+      
+      Telephone: +1 201 232 2851
+      Email: sghosh@xxxxxxxxxxxxxxxxxxxxx
+
+      Nagios Information:
+        http://www.nagios.org
+      "
+  DESCRIPTION
+      "Objects for Nagios(tm) events.  There are 2 primary tables
+      reflecting the division in Nagios for Host events and
+      Service events.
+
+      The event tables are extended by the HostNotifyTable and the 
+      ServiceNotifyTable to keep track of the notifications based on events.
+      
+      The tables entries themselves are not accessible but are used for OID
+      entries for TRAP/INFORM notifications.
+
+      These objects are based on the macros defined in Nagios v2.0
+      "
+  REVISION "200503090000Z" -- March 9, 2005
+  DESCRIPTION
+       "Spell check"
+  REVISION "200501200000Z" --January 20, 2005
+  DESCRIPTION
+      "Initial Version"
+	::= { nagios 1 }
+
+
+nagiosHostEventTable OBJECT-TYPE 
+  SYNTAX      SEQUENCE OF HostEventEntry
+  MAX-ACCESS  not-accessible
+  STATUS      current
+  DESCRIPTION
+    "Table of Nagios host events"
+  ::= { nagiosNotify 1 }
+
+HostEventEntry ::= SEQUENCE {
+  nHostEventIndex    Integer32,
+  nHostname          OCTET STRING,
+  nHostAlias         OCTET STRING,
+  nHostStateID       HostStateID,
+  nHostStateType     HostStateType,
+  nHostAttempt       Integer32,
+  nHostDurationSec   Integer32,
+  nHostGroupName     OCTET STRING,
+  nHostLastCheck     INTEGER,
+  nHostLastChange    INTEGER,
+  nHostLastUp        INTEGER,
+  nHostLastDown      INTEGER,
+  nHostLastUnreachable INTEGER,
+  nHostOutput        OCTET STRING,
+  nHostPerfData      OCTET STRING
+  }
+  
+nagiosHostEventEntry  OBJECT-TYPE
+  SYNTAX      HostEventEntry
+  MAX-ACCESS  not-accessible
+  STATUS      current
+  DESCRIPTION
+    "Each notification event"
+  INDEX { nHostEventIndex }
+  ::= { nagiosHostEventTable 1 }
+  
+nHostEventIndex OBJECT-TYPE
+  SYNTAX     Integer32 (1..65535)
+  MAX-ACCESS not-accessible
+  STATUS     current
+  DESCRIPTION 
+    "This object uniquely identifies this host event entry.  It is generated
+		by the SNMP application and is not related to any Nagios data."
+  ::= { nagiosHostEventEntry 1 }
+
+nHostname    OBJECT-TYPE
+  SYNTAX     OCTET STRING
+  MAX-ACCESS read-only
+  STATUS     current
+  DESCRIPTION 
+    "Hostname as specified in the Nagios configuration file."
+  ::= { nagiosHostEventEntry 2 }
+
+nHostAlias   OBJECT-TYPE
+  SYNTAX     OCTET STRING
+  MAX-ACCESS read-only
+  STATUS     current
+  DESCRIPTION
+    "The host alias as specified in the Nagios configuration file"
+  ::= { nagiosHostEventEntry 3 }
+  
+nHostStateID OBJECT-TYPE
+  SYNTAX     HostStateID
+  MAX-ACCESS read-only
+  STATUS     current
+  DESCRIPTION
+    "The host state as defined by the HOSTSTATEID macro"
+  ::= { nagiosHostEventEntry 4 }
+
+nHostStateType  OBJECT-TYPE
+  SYNTAX     HostStateType
+  MAX-ACCESS read-only
+  STATUS     current
+  DESCRIPTION
+    "The host state as defined by the HOSTSTATETYPE macro"
+  ::= { nagiosHostEventEntry 5 }
+  
+nHostAttempt  OBJECT-TYPE
+  SYNTAX     Integer32
+  MAX-ACCESS read-only
+  STATUS     current
+  DESCRIPTION
+    "The number of the current host check retry. For instance, if this is the 
+    second time that the host is being rechecked, this will be the number two. 
+    Current attempt number is really only useful when writing host event 
+    handlers for soft states that take a specific action based on the host retry 
+    number. The host state as defined by the HOSTSTATEID macro"
+  ::= { nagiosHostEventEntry 6 }
+
+nHostDurationSec   OBJECT-TYPE
+  SYNTAX     Integer32
+  MAX-ACCESS read-only
+  STATUS     current
+  DESCRIPTION
+   "A number indicating the number of seconds that the host has spent in its 
+   current state"
+  ::= { nagiosHostEventEntry 7 }
+  
+nHostGroupName   OBJECT-TYPE
+  SYNTAX     OCTET STRING
+  MAX-ACCESS read-only
+  STATUS     current
+  DESCRIPTION
+    "The short name of the hostgroup that this host belongs to. This value is 
+    taken from the hostgroup_name directive in the hostgroup definition. If the 
+    host belongs to more than one hostgroup this macro will contain the name of
+    just one of them."
+  ::= { nagiosHostEventEntry 8 }
+  
+nHostLastCheck  OBJECT-TYPE
+  SYNTAX     INTEGER
+  MAX-ACCESS read-only
+  STATUS     current
+  DESCRIPTION
+   "This is a timestamp in time_t format (seconds since the UNIX epoch) 
+   indicating the time at which a check of the host was last performed."
+  ::= { nagiosHostEventEntry 9 }
+
+nHostLastChange  OBJECT-TYPE
+  SYNTAX     INTEGER
+  MAX-ACCESS read-only
+  STATUS     current
+  DESCRIPTION
+   "This is a timestamp in time_t format (seconds since the UNIX epoch)
+   indicating the time the host last changed state."
+  ::= { nagiosHostEventEntry 10 }
+
+nHostLastUp  OBJECT-TYPE
+  SYNTAX     INTEGER
+  MAX-ACCESS read-only
+  STATUS     current
+  DESCRIPTION
+    "This is a timestamp in time_t format (seconds since the UNIX epoch)
+    indicating the time at which the host was last detected as being in an UP
+    state."
+  ::= { nagiosHostEventEntry 11 }
+  
+nHostLastDown OBJECT-TYPE
+  SYNTAX     INTEGER
+  MAX-ACCESS read-only
+  STATUS     current
+  DESCRIPTION
+    "This is a timestamp in time_t format (seconds since the UNIX epoch)
+    indicating the time at which the host was last detected as being in an
+    DOWN state."
+  ::= { nagiosHostEventEntry 12 }
+
+nHostLastUnreachable OBJECT-TYPE
+  SYNTAX     INTEGER
+  MAX-ACCESS read-only
+  STATUS     current
+  DESCRIPTION
+    "This is a timestamp in time_t format (seconds since the UNIX epoch)
+    indicating the time at which the host was last detected as being in an
+    UNREACHABLE state."
+  ::= { nagiosHostEventEntry 13 }
+  
+nHostOutput  OBJECT-TYPE
+  SYNTAX     OCTET STRING
+  MAX-ACCESS read-only
+  STATUS     current
+  DESCRIPTION
+    "The text output from the last host check (i.e. Ping OK)."
+  ::= { nagiosHostEventEntry 14 }
+
+nHostPerfData OBJECT-TYPE
+  SYNTAX     OCTET STRING
+  MAX-ACCESS read-only
+  STATUS     current
+  DESCRIPTION
+    "This object contains any performance data that may have been returned 
+    by the last host check."
+  ::= { nagiosHostEventEntry 15 }
+
+
+
+--
+-- Host Notifications
+
+nagiosHostNotifyTable OBJECT-TYPE
+  SYNTAX     SEQUENCE OF HostNotifyEntry
+  MAX-ACCESS  not-accessible
+  STATUS      current
+  DESCRIPTION
+    "Table of Nagios host notifications"
+  ::= {nagiosNotify 2}
+
+HostNotifyEntry ::= SEQUENCE {
+  nHostNotifyType    NotifyType,
+  nHostNotifyNum     Gauge32,    -- was Integer32,
+  nHostAckAuthor     OCTET STRING,
+  nHostAckComment    OCTET STRING
+  }
+
+nagiosHostNotifyEntry  OBJECT-TYPE
+  SYNTAX      HostNotifyEntry
+  MAX-ACCESS  not-accessible
+  STATUS      current
+  DESCRIPTION
+   "Nagios host notifications extends the nagiosHostEventTable when a
+   notification is generated for an event."
+  INDEX { nHostEventIndex }
+  ::= { nagiosHostNotifyTable 1 }
+
+nHostNotifyType  OBJECT-TYPE
+  SYNTAX     NotifyType
+  MAX-ACCESS read-only
+  STATUS     current
+  DESCRIPTION 
+    "This identifies the type of notification that is being sent
+    (PROBLEM, RECOVERY, ACKNOWLEDGEMENT, FLAPPINGSTART or FLAPPINGSTOP)"
+  ::= { nagiosHostNotifyEntry 1 }
+  
+nHostNotifyNum OBJECT-TYPE
+  SYNTAX     Gauge32    -- was NotifyType
+  MAX-ACCESS read-only
+  STATUS     current
+  DESCRIPTION 
+    "This identifies the current notification number for the service or host.
+		The notification number increases by one (1) each time a new notification
+		is sent out for a host or service (except for acknowledgements). The 
+		notification number is reset to 0 when the host or service recovers 
+		(after the recovery notification has gone out). Acknowledgements do not
+		cause the notification number to increase."
+		::= { nagiosHostNotifyEntry 2 }
+
+nHostAckAuthor  OBJECT-TYPE
+  SYNTAX     OCTET STRING
+  MAX-ACCESS read-only
+  STATUS     current
+  DESCRIPTION
+    "A string containing the name of the user who acknowledged the host 
+    problem. This macro is only valid in notifications where the 
+    $NOTIFICATIONTYPE$ macro is set to ACKNOWLEDGEMENT."
+  ::= { nagiosHostNotifyEntry 3 } 
+  
+nHostAckComment   OBJECT-TYPE
+  SYNTAX     OCTET STRING
+  MAX-ACCESS read-only
+  STATUS     current
+  DESCRIPTION
+    "A string containing the acknowledgement comment that was entered by 
+    the user who acknowledged the host problem. This macro is only valid 
+    in notifications where the $NOTIFICATIONTYPE$ macro is set to ACKNOWLEDGEMENT"  
+  ::= { nagiosHostNotifyEntry 4 } 
+
+
+-- 
+-- Service Events 
+-- 
+
+
+nagiosSvcEventTable OBJECT-TYPE
+  SYNTAX      SEQUENCE OF SvcEventEntry
+  MAX-ACCESS  not-accessible
+  STATUS      current
+  DESCRIPTION
+    "Table of Nagios service notifications"
+  ::= { nagiosNotify 3 }
+
+SvcEventEntry ::= SEQUENCE {
+  nSvcEventIndex    Integer32,
+  nSvcHostname      OCTET STRING,
+  nSvcHostAlias     OCTET STRING,
+  nSvcHostStateID   HostStateID,
+  nSvcHostStateType HostStateType,
+  nSvcDesc          OCTET STRING,
+  nSvcStateID       ServiceStateID,
+  nSvcAttempt       Integer32,
+  nSvcDurationSec   Integer32,
+  nSvcGroupName     OCTET STRING,
+  nSvcLastCheck     INTEGER,
+  nSvcLastChange    INTEGER,
+  nSvcLastOK        INTEGER,
+  nSvcLastWarn      INTEGER,
+  nSvcLastCrit      INTEGER,
+  nSvcLastUnkn      INTEGER,
+  nSvcOutput        OCTET STRING,
+  nSvcPerfData      OCTET STRING
+  }
+
+nagiosSvcEventEntry OBJECT-TYPE
+  SYNTAX        SvcEventEntry
+  MAX-ACCESS    not-accessible
+  STATUS        current
+  DESCRIPTION
+    "Table of Nagios service events."
+  INDEX { nSvcEventIndex }
+  ::= { nagiosSvcEventTable 1 }
+
+nSvcEventIndex OBJECT-TYPE
+  SYNTAX       Integer32 (1..65535)
+  MAX-ACCESS   not-accessible
+  STATUS       current
+  DESCRIPTION
+   "This object uniquely identifies this service event entry"
+  ::= { nagiosSvcEventEntry 1 }
+  
+nSvcHostname      OBJECT-TYPE
+  SYNTAX          OCTET STRING
+  MAX-ACCESS      read-only
+  STATUS          current
+  DESCRIPTION
+    "Hostname as specified in the Nagios configuration file."
+  ::= { nagiosSvcEventEntry 2 }
+
+nSvcHostAlias     OBJECT-TYPE
+  SYNTAX          OCTET STRING
+  MAX-ACCESS      read-only
+  STATUS          current
+  DESCRIPTION
+    "The host alias as specified in the Nagios configuration file"
+  ::= { nagiosSvcEventEntry 3 }
+  
+nSvcHostStateID   OBJECT-TYPE
+  SYNTAX          HostStateID
+  MAX-ACCESS      read-only
+  STATUS          current
+  DESCRIPTION
+    "A number that corresponds to the current state of the service: 0=OK,
+    1=WARNING, 2=CRITICAL, 3=UNKNOWN."
+  ::= { nagiosSvcEventEntry 4 }
+  
+nSvcHostStateType OBJECT-TYPE 
+  SYNTAX          HostStateType
+  MAX-ACCESS      read-only
+  STATUS          current
+  DESCRIPTION
+    "Whether the host is in a hard or soft state."
+  ::= { nagiosSvcEventEntry 5 }
+  
+nSvcDesc          OBJECT-TYPE
+  SYNTAX          OCTET STRING
+  MAX-ACCESS      read-only
+  STATUS          current
+  DESCRIPTION
+    "This value is taken from the description directive of the service
+    definition."
+  ::= { nagiosSvcEventEntry 6 }
+
+nSvcStateID       OBJECT-TYPE
+  SYNTAX          ServiceStateID
+  MAX-ACCESS      read-only
+  STATUS          current
+  DESCRIPTION
+    " A number that corresponds to the current state of the service: 0=OK,
+    1=WARNING, 2=CRITICAL, 3=UNKNOWN"
+  ::= {  nagiosSvcEventEntry 7 }
+  
+nSvcAttempt       OBJECT-TYPE
+  SYNTAX          Integer32
+  MAX-ACCESS      read-only
+  STATUS          current
+  DESCRIPTION
+    "The number of the current service check retry. For instance, if this is
+    the second time that the service is being rechecked, this will be the
+    number two. Current attempt number is really only useful when writing
+    service event handlers for soft states that take a specific action based
+    on the service retry number."
+  ::= { nagiosSvcEventEntry 8 }
+
+nSvcDurationSec   OBJECT-TYPE
+  SYNTAX          Integer32
+  MAX-ACCESS      read-only
+  STATUS          current
+  DESCRIPTION
+    "A number indicating the number of seconds that the service has spent in
+    its current state."
+  ::= { nagiosSvcEventEntry 9 }
+
+nSvcGroupName     OBJECT-TYPE
+  SYNTAX          OCTET STRING
+  MAX-ACCESS      read-only
+  STATUS          current
+  DESCRIPTION
+    "The short name of the servicegroup that this service belongs to. This
+    value is taken from the servicegroup_name directive in the servicegroup
+    definition. If the service belongs to more than one servicegroup this
+    object will contain the name of just one of them."
+  ::= { nagiosSvcEventEntry 10 }
+
+nSvcLastCheck     OBJECT-TYPE
+  SYNTAX          INTEGER
+  MAX-ACCESS      read-only
+  STATUS          current
+  DESCRIPTION
+    "This is a timestamp in time_t format (seconds since the UNIX epoch)
+    indicating the time at which a check of the service was last performed."
+  ::= { nagiosSvcEventEntry 11 }
+
+nSvcLastChange    OBJECT-TYPE
+  SYNTAX          INTEGER
+  MAX-ACCESS      read-only
+  STATUS          current
+  DESCRIPTION
+    "This is a timestamp in time_t format (seconds since the UNIX epoch)
+    indicating the time the service last changed state."
+  ::= { nagiosSvcEventEntry 12 }
+
+nSvcLastOK        OBJECT-TYPE
+  SYNTAX          INTEGER
+  MAX-ACCESS      read-only
+  STATUS          current
+  DESCRIPTION
+    "This is a timestamp in time_t format (seconds since the UNIX epoch)
+    indicating the time at which the service was last detected as being in an
+    OK state."
+  ::= { nagiosSvcEventEntry 13 }
+
+nSvcLastWarn      OBJECT-TYPE
+  SYNTAX          INTEGER
+  MAX-ACCESS      read-only
+  STATUS          current
+  DESCRIPTION
+    "This is a timestamp in time_t format (seconds since the UNIX epoch)
+    indicating the time at which the service was last detected as being in a
+    WARNING state."
+  ::= { nagiosSvcEventEntry 14 }
+
+nSvcLastCrit      OBJECT-TYPE
+  SYNTAX          INTEGER
+  MAX-ACCESS      read-only
+  STATUS          current
+  DESCRIPTION
+    "This is a timestamp in time_t format (seconds since the UNIX epoch)
+    indicating the time at which the service was last detected as being in a
+    CRITICAL state."
+  ::= { nagiosSvcEventEntry 15 }
+
+nSvcLastUnkn      OBJECT-TYPE
+  SYNTAX          INTEGER
+  MAX-ACCESS      read-only
+  STATUS          current
+  DESCRIPTION
+    "This is a timestamp in time_t format (seconds since the UNIX epoch)
+    indicating the time at which the service was last detected as being in an
+    UNKNOWN state."
+  ::= { nagiosSvcEventEntry 16 }
+  
+nSvcOutput        OBJECT-TYPE
+  SYNTAX          OCTET STRING
+  MAX-ACCESS      read-only
+  STATUS          current
+  DESCRIPTION
+    "The text output from the last service check (i.e. Ping OK)."
+  ::= { nagiosSvcEventEntry 17 }
+
+nSvcPerfData      OBJECT-TYPE
+  SYNTAX          OCTET STRING
+  MAX-ACCESS      read-only
+  STATUS          current
+  DESCRIPTION
+    "This object contains any performance data that may have been returned by
+    the last service check."
+  ::= { nagiosSvcEventEntry 18 }
+
+
+-- 
+-- Service Notifications
+-- 
+
+nagiosSvcNotifyTable OBJECT-TYPE
+  SYNTAX       SEQUENCE OF SvcNotifyEntry
+  MAX-ACCESS   not-accessible
+  STATUS       current
+  DESCRIPTION
+    "Table of Nagios service notifications."
+  ::= { nagiosNotify 4 }
+  
+SvcNotifyEntry ::= SEQUENCE {
+  nSvcNotifyType    NotifyType,
+  nSvcNotifyNum     Gauge32,    -- Integer32,
+  nSvcAckAuthor     OCTET STRING,
+  nSvcAckComment    OCTET STRING
+  }
+
+nagiosSvcNotifyEntry OBJECT-TYPE
+  SYNTAX       SvcNotifyEntry
+  MAX-ACCESS   not-accessible
+  STATUS       current
+  DESCRIPTION
+    "Nagios service notifications extends the nagiosSvcEnevtsTable when
+    a notification is generated for an event."
+  INDEX { nSvcEventIndex }
+  ::= { nagiosSvcNotifyTable 1}
+  
+  
+nSvcNotifyType OBJECT-TYPE
+  SYNTAX       NotifyType
+  MAX-ACCESS   read-only
+  STATUS       current
+  DESCRIPTION
+    "A string identifying the type of notification that is being sent
+    (PROBLEM, RECOVERY, ACKNOWLEDGEMENT, FLAPPINGSTART or FLAPPINGSTOP)."
+  ::= { nagiosSvcNotifyEntry 1 }
+
+nSvcNotifyNum  OBJECT-TYPE
+  SYNTAX       Gauge32  -- Integer32
+  MAX-ACCESS   read-only
+  STATUS       current
+  DESCRIPTION
+    "The current notification number for the service or host. The notification
+    number increases by one (1) each time a new notification is sent out for a
+    host or service (except for acknowledgements). The notification number is
+    reset to 0 when the host or service recovers (after the recovery
+    notification has gone out). Acknowledgements do not cause the notification
+    number to increase."
+  ::= { nagiosSvcNotifyEntry 2 }
+
+nSvcAckAuthor  OBJECT-TYPE
+  SYNTAX       OCTET STRING
+  MAX-ACCESS   read-only
+  STATUS       current
+  DESCRIPTION
+    "A string containing the name of the user who acknowledged the service
+    problem. This object is only valid in notifications where the
+    nSvcNotifyType object is set to ACKNOWLEDGEMENT."
+  ::= { nagiosSvcNotifyEntry 3 }
+
+nSvcAckComment OBJECT-TYPE
+  SYNTAX       OCTET STRING
+  MAX-ACCESS   read-only
+  STATUS       current
+  DESCRIPTION
+    "A string containing the acknowledgement comment that was entered by the
+    user who acknowledged the service problem.  This object is only valid in
+    notifications where the nSvcNotifyType object is set to ACKNOWLEDGEMENT."
+  ::= { nagiosSvcNotifyEntry 4 }
+    
+
+--
+-- Events and Notifications
+--
+
+nHostEvent  NOTIFICATION-TYPE
+  OBJECTS { nHostname, nHostStateID, nHostStateType, nHostAttempt,
+            nHostDurationSec, nHostGroupName, nHostLastCheck, nHostLastChange, 
+            nHostOutput }
+  STATUS  current
+  DESCRIPTION
+    "The SNMP trap that is generated as a result of an event with the host
+    in Nagios."
+
+  ::= { nagiosNotify 5 }
+
+nHostNotify NOTIFICATION-TYPE
+  OBJECTS { nHostNotifyType, nHostNotifyNum, nHostAckAuthor, nHostAckComment,
+            nHostname, nHostStateID, nHostStateType, nHostAttempt,
+            nHostDurationSec, nHostGroupName, nHostLastCheck, nHostLastChange,
+            nHostOutput  }
+  STATUS  current
+  DESCRIPTION
+    "The SNMP trap that is generated as a result of an event requiring
+    notification for a host in Nagios."
+  ::= { nagiosNotify 6 }
+
+nSvcEvent  NOTIFICATION-TYPE
+  OBJECTS { nHostname, nHostStateID, nSvcDesc, nSvcStateID, nSvcAttempt,
+            nSvcDurationSec, nSvcGroupName, nSvcLastCheck, nSvcLastChange,
+            nSvcOutput }
+  STATUS  current
+  DESCRIPTION
+    "The SNMP trap that is generated as a result of an event with the service
+    in Nagios."
+  ::= { nagiosNotify 7 }
+
+nSvcNotify NOTIFICATION-TYPE
+  OBJECTS { nSvcNotifyType, nSvcNotifyNum, nSvcAckAuthor, nSvcAckComment,
+            nHostname, nHostStateID, nSvcDesc, nSvcStateID, nSvcAttempt,
+            nSvcDurationSec, nSvcGroupName, nSvcLastCheck, nSvcLastChange,
+            nSvcOutput }
+  STATUS  current
+  DESCRIPTION
+    "The SNMP trap that is generated as a result of an event requiring
+    notification for a service in Nagios."
+  ::= { nagiosNotify 8 }
+
+
+END
diff --git a/files/mibs/NAGIOS-ROOT-MIB b/files/mibs/NAGIOS-ROOT-MIB
new file mode 100644
index 0000000..1aa88eb
--- /dev/null
+++ b/files/mibs/NAGIOS-ROOT-MIB
@@ -0,0 +1,86 @@
+NAGIOS-ROOT-MIB DEFINITIONS ::= BEGIN
+IMPORTS
+  MODULE-IDENTITY,  enterprises 
+    FROM SNMPv2-SMI
+  TEXTUAL-CONVENTION
+    FROM SNMPv2-TC;
+
+
+nagios MODULE-IDENTITY
+    LAST-UPDATED "200503090000Z" -- March 9, 2005
+    ORGANIZATION "Nagios"
+    CONTACT-INFO
+      " Subhendu Ghosh
+      
+      Telephone: +1 201 232 2851
+      Email: sghosh@xxxxxxxxxxxxxxxxxxxxx
+
+      Nagios Information:
+        http://www.nagios.org
+      "
+    DESCRIPTION
+      "Objects for Nagios(tm) NMS"
+    REVISION "200503090000Z" -- March 9, 2005
+    DESCRIPTION
+      "Spell check"
+		REVISION "200501200000Z" --January 20, 2005
+    DESCRIPTION
+      "Initial Version"
+    ::= {enterprises 20006}
+
+--
+-- Textual Conventions
+--
+
+NotifyType ::= TEXTUAL-CONVENTION
+  STATUS current
+  DESCRIPTION
+    "A string identifying the type of notification that is being sent 
+    (PROBLEM, RECOVERY, ACKNOWLEDGEMENT, FLAPPINGSTART or FLAPPINGSTOP).
+    "
+  SYNTAX INTEGER {
+    problem(0),
+    recovery(1),
+    acknowledgement(2),
+    flappingstart(3),
+    flappingstop(4)
+    }
+
+HostStateID ::= TEXTUAL-CONVENTION
+  STATUS current
+  DESCRIPTION
+    "A number that corresponds to the current state of the host: 0=UP, 1=DOWN, 
+    2=UNREACHABLE."
+  SYNTAX INTEGER {
+    up(0),
+    down(1),
+    unreachable(3)
+    }
+        
+HostStateType ::= TEXTUAL-CONVENTION
+  STATUS current
+  DESCRIPTION
+    "A string indicating the state type for the current host check (HARD or 
+    SOFT). Soft states occur when host checks return a non-OK (non-UP) state 
+    and are in the process of being retried. Hard states result when host 
+    checks have been checked a specified maximum number of times."
+  SYNTAX INTEGER {
+    hard(0),
+    soft(1)
+    }
+
+ServiceStateID ::= TEXTUAL-CONVENTION
+  STATUS current
+  DESCRIPTION
+    "A number that corresponds to the current state of the service: 0=OK, 
+    1=WARNING, 2=CRITICAL, 3=UNKNOWN.
+    "
+  SYNTAX INTEGER{
+    ok(0),
+    warning(1),
+    critical(2),
+    unknown(3)
+    }
+
+
+END
diff --git a/files/mibs/README-MIBs b/files/mibs/README-MIBs
new file mode 100644
index 0000000..ef8094b
--- /dev/null
+++ b/files/mibs/README-MIBs
@@ -0,0 +1,17 @@
+# These files change once in a lifetime (most have not changed in 10 years)
+# There are no packages in the standard repos that contain any of them
+# Anyway, to check for new versions, here are the sources:
+
+# nagios
+https://raw.githubusercontent.com/nagios-plugins/nagios-mib/master/MIB/NAGIOS-ROOT-MIB
+https://raw.githubusercontent.com/nagios-plugins/nagios-mib/master/MIB/NAGIOS-NOTIFY-MIB
+
+# net-snmp
+https://sourceforge.net/p/net-snmp/code/ci/master/tree/mibs/SNMPv2-SMI.txt?format=raw
+https://sourceforge.net/p/net-snmp/code/ci/master/tree/mibs/SNMPv2-MIB.txt?format=raw
+https://sourceforge.net/p/net-snmp/code/ci/master/tree/mibs/SNMPv2-TC.txt?format=raw
+
+# net-snmp alternative source
+https://raw.githubusercontent.com/hardaker/net-snmp/master/mibs/SNMPv2-SMI.txt
+https://raw.githubusercontent.com/hardaker/net-snmp/master/mibs/SNMPv2-MIB.txt
+https://raw.githubusercontent.com/hardaker/net-snmp/master/mibs/SNMPv2-TC.txt
diff --git a/files/mibs/SNMPv2-MIB.txt b/files/mibs/SNMPv2-MIB.txt
new file mode 100644
index 0000000..8c82830
--- /dev/null
+++ b/files/mibs/SNMPv2-MIB.txt
@@ -0,0 +1,854 @@
+SNMPv2-MIB DEFINITIONS ::= BEGIN
+
+IMPORTS
+    MODULE-IDENTITY, OBJECT-TYPE, NOTIFICATION-TYPE,
+    TimeTicks, Counter32, snmpModules, mib-2
+        FROM SNMPv2-SMI
+    DisplayString, TestAndIncr, TimeStamp
+
+        FROM SNMPv2-TC
+    MODULE-COMPLIANCE, OBJECT-GROUP, NOTIFICATION-GROUP
+        FROM SNMPv2-CONF;
+
+snmpMIB MODULE-IDENTITY
+    LAST-UPDATED "200210160000Z"
+    ORGANIZATION "IETF SNMPv3 Working Group"
+    CONTACT-INFO
+            "WG-EMail:   snmpv3@xxxxxxxxxxxxxxxxx
+             Subscribe:  snmpv3-request@xxxxxxxxxxxxxxxxx
+
+             Co-Chair:   Russ Mundy
+                         Network Associates Laboratories
+             postal:     15204 Omega Drive, Suite 300
+                         Rockville, MD 20850-4601
+                         USA
+             EMail:      mundy@xxxxxxxxxxx
+             phone:      +1 301 947-7107
+
+             Co-Chair:   David Harrington
+                         Enterasys Networks
+             postal:     35 Industrial Way
+                         P. O. Box 5005
+                         Rochester, NH 03866-5005
+                         USA
+             EMail:      dbh@xxxxxxxxxxxxx
+             phone:      +1 603 337-2614
+
+             Editor:     Randy Presuhn
+                         BMC Software, Inc.
+             postal:     2141 North First Street
+                         San Jose, CA 95131
+                         USA
+             EMail:      randy_presuhn@xxxxxxx
+             phone:      +1 408 546-1006"
+    DESCRIPTION
+            "The MIB module for SNMP entities.
+
+             Copyright (C) The Internet Society (2002). This
+             version of this MIB module is part of RFC 3418;
+             see the RFC itself for full legal notices.
+            "
+    REVISION      "200210160000Z"
+    DESCRIPTION
+            "This revision of this MIB module was published as
+             RFC 3418."
+    REVISION      "199511090000Z"
+    DESCRIPTION
+            "This revision of this MIB module was published as
+             RFC 1907."
+    REVISION      "199304010000Z"
+    DESCRIPTION
+            "The initial revision of this MIB module was published
+            as RFC 1450."
+    ::= { snmpModules 1 }
+
+snmpMIBObjects OBJECT IDENTIFIER ::= { snmpMIB 1 }
+
+--  ::= { snmpMIBObjects 1 }        this OID is obsolete
+--  ::= { snmpMIBObjects 2 }        this OID is obsolete
+--  ::= { snmpMIBObjects 3 }        this OID is obsolete
+
+-- the System group
+--
+-- a collection of objects common to all managed systems.
+
+system   OBJECT IDENTIFIER ::= { mib-2 1 }
+
+sysDescr OBJECT-TYPE
+    SYNTAX      DisplayString (SIZE (0..255))
+    MAX-ACCESS  read-only
+    STATUS      current
+    DESCRIPTION
+            "A textual description of the entity.  This value should
+            include the full name and version identification of
+            the system's hardware type, software operating-system,
+            and networking software."
+    ::= { system 1 }
+
+sysObjectID OBJECT-TYPE
+    SYNTAX      OBJECT IDENTIFIER
+    MAX-ACCESS  read-only
+    STATUS      current
+    DESCRIPTION
+            "The vendor's authoritative identification of the
+            network management subsystem contained in the entity.
+            This value is allocated within the SMI enterprises
+            subtree (1.3.6.1.4.1) and provides an easy and
+            unambiguous means for determining `what kind of box' is
+            being managed.  For example, if vendor `Flintstones,
+            Inc.' was assigned the subtree 1.3.6.1.4.1.424242,
+            it could assign the identifier 1.3.6.1.4.1.424242.1.1
+            to its `Fred Router'."
+    ::= { system 2 }
+
+sysUpTime OBJECT-TYPE
+    SYNTAX      TimeTicks
+    MAX-ACCESS  read-only
+    STATUS      current
+    DESCRIPTION
+            "The time (in hundredths of a second) since the
+            network management portion of the system was last
+            re-initialized."
+    ::= { system 3 }
+
+sysContact OBJECT-TYPE
+    SYNTAX      DisplayString (SIZE (0..255))
+    MAX-ACCESS  read-write
+    STATUS      current
+    DESCRIPTION
+            "The textual identification of the contact person for
+            this managed node, together with information on how
+            to contact this person.  If no contact information is
+            known, the value is the zero-length string."
+    ::= { system 4 }
+
+sysName OBJECT-TYPE
+    SYNTAX      DisplayString (SIZE (0..255))
+    MAX-ACCESS  read-write
+    STATUS      current
+    DESCRIPTION
+            "An administratively-assigned name for this managed
+            node.  By convention, this is the node's fully-qualified
+            domain name.  If the name is unknown, the value is
+            the zero-length string."
+    ::= { system 5 }
+
+sysLocation OBJECT-TYPE
+    SYNTAX      DisplayString (SIZE (0..255))
+    MAX-ACCESS  read-write
+    STATUS      current
+    DESCRIPTION
+            "The physical location of this node (e.g., 'telephone
+            closet, 3rd floor').  If the location is unknown, the
+            value is the zero-length string."
+    ::= { system 6 }
+
+sysServices OBJECT-TYPE
+    SYNTAX      INTEGER (0..127)
+    MAX-ACCESS  read-only
+    STATUS      current
+    DESCRIPTION
+            "A value which indicates the set of services that this
+            entity may potentially offer.  The value is a sum.
+
+            This sum initially takes the value zero. Then, for
+            each layer, L, in the range 1 through 7, that this node
+            performs transactions for, 2 raised to (L - 1) is added
+            to the sum.  For example, a node which performs only
+            routing functions would have a value of 4 (2^(3-1)).
+            In contrast, a node which is a host offering application
+            services would have a value of 72 (2^(4-1) + 2^(7-1)).
+            Note that in the context of the Internet suite of
+            protocols, values should be calculated accordingly:
+
+                 layer      functionality
+                   1        physical (e.g., repeaters)
+                   2        datalink/subnetwork (e.g., bridges)
+                   3        internet (e.g., supports the IP)
+                   4        end-to-end  (e.g., supports the TCP)
+                   7        applications (e.g., supports the SMTP)
+
+            For systems including OSI protocols, layers 5 and 6
+            may also be counted."
+    ::= { system 7 }
+
+-- object resource information
+--
+-- a collection of objects which describe the SNMP entity's
+-- (statically and dynamically configurable) support of
+-- various MIB modules.
+
+sysORLastChange OBJECT-TYPE
+    SYNTAX     TimeStamp
+    MAX-ACCESS read-only
+    STATUS     current
+    DESCRIPTION
+            "The value of sysUpTime at the time of the most recent
+            change in state or value of any instance of sysORID."
+    ::= { system 8 }
+
+sysORTable OBJECT-TYPE
+    SYNTAX     SEQUENCE OF SysOREntry
+    MAX-ACCESS not-accessible
+    STATUS     current
+    DESCRIPTION
+            "The (conceptual) table listing the capabilities of
+            the local SNMP application acting as a command
+            responder with respect to various MIB modules.
+            SNMP entities having dynamically-configurable support
+            of MIB modules will have a dynamically-varying number
+            of conceptual rows."
+    ::= { system 9 }
+
+sysOREntry OBJECT-TYPE
+    SYNTAX     SysOREntry
+    MAX-ACCESS not-accessible
+    STATUS     current
+    DESCRIPTION
+            "An entry (conceptual row) in the sysORTable."
+    INDEX      { sysORIndex }
+    ::= { sysORTable 1 }
+
+SysOREntry ::= SEQUENCE {
+    sysORIndex     INTEGER,
+    sysORID        OBJECT IDENTIFIER,
+    sysORDescr     DisplayString,
+    sysORUpTime    TimeStamp
+}
+
+sysORIndex OBJECT-TYPE
+    SYNTAX     INTEGER (1..2147483647)
+    MAX-ACCESS not-accessible
+    STATUS     current
+    DESCRIPTION
+            "The auxiliary variable used for identifying instances
+            of the columnar objects in the sysORTable."
+    ::= { sysOREntry 1 }
+
+sysORID OBJECT-TYPE
+    SYNTAX     OBJECT IDENTIFIER
+    MAX-ACCESS read-only
+    STATUS     current
+    DESCRIPTION
+            "An authoritative identification of a capabilities
+            statement with respect to various MIB modules supported
+            by the local SNMP application acting as a command
+            responder."
+    ::= { sysOREntry 2 }
+
+sysORDescr OBJECT-TYPE
+    SYNTAX     DisplayString
+    MAX-ACCESS read-only
+    STATUS     current
+    DESCRIPTION
+            "A textual description of the capabilities identified
+            by the corresponding instance of sysORID."
+    ::= { sysOREntry 3 }
+
+sysORUpTime OBJECT-TYPE
+    SYNTAX     TimeStamp
+    MAX-ACCESS read-only
+    STATUS     current
+    DESCRIPTION
+            "The value of sysUpTime at the time this conceptual
+            row was last instantiated."
+    ::= { sysOREntry 4 }
+
+-- the SNMP group
+--
+-- a collection of objects providing basic instrumentation and
+-- control of an SNMP entity.
+
+snmp     OBJECT IDENTIFIER ::= { mib-2 11 }
+
+snmpInPkts OBJECT-TYPE
+    SYNTAX     Counter32
+    MAX-ACCESS read-only
+    STATUS     current
+    DESCRIPTION
+            "The total number of messages delivered to the SNMP
+            entity from the transport service."
+    ::= { snmp 1 }
+
+snmpInBadVersions OBJECT-TYPE
+    SYNTAX     Counter32
+    MAX-ACCESS read-only
+    STATUS     current
+    DESCRIPTION
+            "The total number of SNMP messages which were delivered
+            to the SNMP entity and were for an unsupported SNMP
+            version."
+    ::= { snmp 3 }
+
+snmpInBadCommunityNames OBJECT-TYPE
+    SYNTAX     Counter32
+    MAX-ACCESS read-only
+    STATUS     current
+    DESCRIPTION
+           "The total number of community-based SNMP messages (for
+           example,  SNMPv1) delivered to the SNMP entity which
+           used an SNMP community name not known to said entity.
+           Also, implementations which authenticate community-based
+           SNMP messages using check(s) in addition to matching
+           the community name (for example, by also checking
+           whether the message originated from a transport address
+           allowed to use a specified community name) MAY include
+           in this value the number of messages which failed the
+           additional check(s).  It is strongly RECOMMENDED that
+
+           the documentation for any security model which is used
+           to authenticate community-based SNMP messages specify
+           the precise conditions that contribute to this value."
+    ::= { snmp 4 }
+
+snmpInBadCommunityUses OBJECT-TYPE
+    SYNTAX     Counter32
+    MAX-ACCESS read-only
+    STATUS     current
+    DESCRIPTION
+           "The total number of community-based SNMP messages (for
+           example, SNMPv1) delivered to the SNMP entity which
+           represented an SNMP operation that was not allowed for
+           the SNMP community named in the message.  The precise
+           conditions under which this counter is incremented
+           (if at all) depend on how the SNMP entity implements
+           its access control mechanism and how its applications
+           interact with that access control mechanism.  It is
+           strongly RECOMMENDED that the documentation for any
+           access control mechanism which is used to control access
+           to and visibility of MIB instrumentation specify the
+           precise conditions that contribute to this value."
+    ::= { snmp 5 }
+
+snmpInASNParseErrs OBJECT-TYPE
+    SYNTAX     Counter32
+    MAX-ACCESS read-only
+    STATUS     current
+    DESCRIPTION
+            "The total number of ASN.1 or BER errors encountered by
+            the SNMP entity when decoding received SNMP messages."
+    ::= { snmp 6 }
+
+snmpEnableAuthenTraps OBJECT-TYPE
+    SYNTAX      INTEGER { enabled(1), disabled(2) }
+    MAX-ACCESS  read-write
+    STATUS      current
+    DESCRIPTION
+            "Indicates whether the SNMP entity is permitted to
+            generate authenticationFailure traps.  The value of this
+            object overrides any configuration information; as such,
+            it provides a means whereby all authenticationFailure
+            traps may be disabled.
+
+            Note that it is strongly recommended that this object
+            be stored in non-volatile memory so that it remains
+            constant across re-initializations of the network
+            management system."
+    ::= { snmp 30 }
+
+snmpSilentDrops OBJECT-TYPE
+    SYNTAX     Counter32
+    MAX-ACCESS read-only
+    STATUS     current
+    DESCRIPTION
+           "The total number of Confirmed Class PDUs (such as
+           GetRequest-PDUs, GetNextRequest-PDUs,
+           GetBulkRequest-PDUs, SetRequest-PDUs, and
+           InformRequest-PDUs) delivered to the SNMP entity which
+           were silently dropped because the size of a reply
+           containing an alternate Response Class PDU (such as a
+           Response-PDU) with an empty variable-bindings field
+           was greater than either a local constraint or the
+           maximum message size associated with the originator of
+           the request."
+    ::= { snmp 31 }
+
+snmpProxyDrops OBJECT-TYPE
+    SYNTAX     Counter32
+    MAX-ACCESS read-only
+    STATUS     current
+    DESCRIPTION
+            "The total number of Confirmed Class PDUs
+            (such as GetRequest-PDUs, GetNextRequest-PDUs,
+            GetBulkRequest-PDUs, SetRequest-PDUs, and
+            InformRequest-PDUs) delivered to the SNMP entity which
+            were silently dropped because the transmission of
+            the (possibly translated) message to a proxy target
+            failed in a manner (other than a time-out) such that
+            no Response Class PDU (such as a Response-PDU) could
+            be returned."
+    ::= { snmp 32 }
+
+-- information for notifications
+--
+-- a collection of objects which allow the SNMP entity, when
+-- supporting a notification originator application,
+-- to be configured to generate SNMPv2-Trap-PDUs.
+
+snmpTrap       OBJECT IDENTIFIER ::= { snmpMIBObjects 4 }
+
+snmpTrapOID OBJECT-TYPE
+    SYNTAX     OBJECT IDENTIFIER
+    MAX-ACCESS accessible-for-notify
+    STATUS     current
+    DESCRIPTION
+            "The authoritative identification of the notification
+            currently being sent.  This variable occurs as
+            the second varbind in every SNMPv2-Trap-PDU and
+            InformRequest-PDU."
+    ::= { snmpTrap 1 }
+
+--  ::= { snmpTrap 2 }   this OID is obsolete
+
+snmpTrapEnterprise OBJECT-TYPE
+    SYNTAX     OBJECT IDENTIFIER
+    MAX-ACCESS accessible-for-notify
+    STATUS     current
+    DESCRIPTION
+            "The authoritative identification of the enterprise
+            associated with the trap currently being sent.  When an
+            SNMP proxy agent is mapping an RFC1157 Trap-PDU
+            into a SNMPv2-Trap-PDU, this variable occurs as the
+            last varbind."
+    ::= { snmpTrap 3 }
+
+--  ::= { snmpTrap 4 }   this OID is obsolete
+
+-- well-known traps
+
+snmpTraps      OBJECT IDENTIFIER ::= { snmpMIBObjects 5 }
+
+coldStart NOTIFICATION-TYPE
+    STATUS  current
+    DESCRIPTION
+            "A coldStart trap signifies that the SNMP entity,
+            supporting a notification originator application, is
+            reinitializing itself and that its configuration may
+            have been altered."
+    ::= { snmpTraps 1 }
+
+warmStart NOTIFICATION-TYPE
+    STATUS  current
+    DESCRIPTION
+            "A warmStart trap signifies that the SNMP entity,
+            supporting a notification originator application,
+            is reinitializing itself such that its configuration
+            is unaltered."
+    ::= { snmpTraps 2 }
+
+-- Note the linkDown NOTIFICATION-TYPE ::= { snmpTraps 3 }
+-- and the linkUp NOTIFICATION-TYPE ::= { snmpTraps 4 }
+-- are defined in RFC 2863 [RFC2863]
+
+authenticationFailure NOTIFICATION-TYPE
+    STATUS  current
+    DESCRIPTION
+            "An authenticationFailure trap signifies that the SNMP
+             entity has received a protocol message that is not
+             properly authenticated.  While all implementations
+             of SNMP entities MAY be capable of generating this
+             trap, the snmpEnableAuthenTraps object indicates
+             whether this trap will be generated."
+    ::= { snmpTraps 5 }
+
+-- Note the egpNeighborLoss notification is defined
+-- as { snmpTraps 6 } in RFC 1213
+
+-- the set group
+--
+-- a collection of objects which allow several cooperating
+-- command generator applications to coordinate their use of the
+-- set operation.
+
+snmpSet        OBJECT IDENTIFIER ::= { snmpMIBObjects 6 }
+
+snmpSetSerialNo OBJECT-TYPE
+    SYNTAX     TestAndIncr
+    MAX-ACCESS read-write
+    STATUS     current
+    DESCRIPTION
+            "An advisory lock used to allow several cooperating
+            command generator applications to coordinate their
+            use of the SNMP set operation.
+
+            This object is used for coarse-grain coordination.
+            To achieve fine-grain coordination, one or more similar
+            objects might be defined within each MIB group, as
+            appropriate."
+    ::= { snmpSet 1 }
+
+-- conformance information
+
+snmpMIBConformance
+               OBJECT IDENTIFIER ::= { snmpMIB 2 }
+
+snmpMIBCompliances
+               OBJECT IDENTIFIER ::= { snmpMIBConformance 1 }
+snmpMIBGroups  OBJECT IDENTIFIER ::= { snmpMIBConformance 2 }
+
+-- compliance statements
+
+--    ::= { snmpMIBCompliances 1 }      this OID is obsolete
+snmpBasicCompliance MODULE-COMPLIANCE
+    STATUS  deprecated
+    DESCRIPTION
+            "The compliance statement for SNMPv2 entities which
+            implement the SNMPv2 MIB.
+
+            This compliance statement is replaced by
+            snmpBasicComplianceRev2."
+    MODULE  -- this module
+        MANDATORY-GROUPS { snmpGroup, snmpSetGroup, systemGroup,
+                           snmpBasicNotificationsGroup }
+
+        GROUP   snmpCommunityGroup
+        DESCRIPTION
+            "This group is mandatory for SNMPv2 entities which
+            support community-based authentication."
+    ::= { snmpMIBCompliances 2 }
+
+snmpBasicComplianceRev2 MODULE-COMPLIANCE
+    STATUS  current
+    DESCRIPTION
+            "The compliance statement for SNMP entities which
+            implement this MIB module."
+    MODULE  -- this module
+        MANDATORY-GROUPS { snmpGroup, snmpSetGroup, systemGroup,
+                           snmpBasicNotificationsGroup }
+
+        GROUP   snmpCommunityGroup
+        DESCRIPTION
+            "This group is mandatory for SNMP entities which
+            support community-based authentication."
+
+        GROUP   snmpWarmStartNotificationGroup
+        DESCRIPTION
+            "This group is mandatory for an SNMP entity which
+            supports command responder applications, and is
+            able to reinitialize itself such that its
+            configuration is unaltered."
+    ::= { snmpMIBCompliances 3 }
+
+-- units of conformance
+
+--  ::= { snmpMIBGroups 1 }           this OID is obsolete
+--  ::= { snmpMIBGroups 2 }           this OID is obsolete
+--  ::= { snmpMIBGroups 3 }           this OID is obsolete
+
+--  ::= { snmpMIBGroups 4 }           this OID is obsolete
+
+snmpGroup OBJECT-GROUP
+    OBJECTS { snmpInPkts,
+              snmpInBadVersions,
+              snmpInASNParseErrs,
+              snmpSilentDrops,
+              snmpProxyDrops,
+              snmpEnableAuthenTraps }
+    STATUS  current
+    DESCRIPTION
+            "A collection of objects providing basic instrumentation
+            and control of an SNMP entity."
+    ::= { snmpMIBGroups 8 }
+
+snmpCommunityGroup OBJECT-GROUP
+    OBJECTS { snmpInBadCommunityNames,
+              snmpInBadCommunityUses }
+    STATUS  current
+    DESCRIPTION
+            "A collection of objects providing basic instrumentation
+            of a SNMP entity which supports community-based
+            authentication."
+    ::= { snmpMIBGroups 9 }
+
+snmpSetGroup OBJECT-GROUP
+    OBJECTS { snmpSetSerialNo }
+    STATUS  current
+    DESCRIPTION
+            "A collection of objects which allow several cooperating
+            command generator applications to coordinate their
+            use of the set operation."
+    ::= { snmpMIBGroups 5 }
+
+systemGroup OBJECT-GROUP
+    OBJECTS { sysDescr, sysObjectID, sysUpTime,
+              sysContact, sysName, sysLocation,
+              sysServices,
+              sysORLastChange, sysORID,
+              sysORUpTime, sysORDescr }
+    STATUS  current
+    DESCRIPTION
+            "The system group defines objects which are common to all
+            managed systems."
+    ::= { snmpMIBGroups 6 }
+
+snmpBasicNotificationsGroup NOTIFICATION-GROUP
+    NOTIFICATIONS { coldStart, authenticationFailure }
+    STATUS        current
+    DESCRIPTION
+       "The basic notifications implemented by an SNMP entity
+        supporting command responder applications."
+    ::= { snmpMIBGroups 7 }
+
+snmpWarmStartNotificationGroup NOTIFICATION-GROUP
+   NOTIFICATIONS { warmStart }
+   STATUS        current
+   DESCRIPTION
+     "An additional notification for an SNMP entity supporting
+     command responder applications, if it is able to reinitialize
+     itself such that its configuration is unaltered."
+  ::= { snmpMIBGroups 11 }
+
+snmpNotificationGroup OBJECT-GROUP
+    OBJECTS { snmpTrapOID, snmpTrapEnterprise }
+    STATUS  current
+    DESCRIPTION
+            "These objects are required for entities
+            which support notification originator applications."
+    ::= { snmpMIBGroups 12 }
+
+-- definitions in RFC 1213 made obsolete by the inclusion of a
+-- subset of the snmp group in this MIB
+
+snmpOutPkts OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of SNMP Messages which were
+            passed from the SNMP protocol entity to the
+            transport service."
+    ::= { snmp 2 }
+
+-- { snmp 7 } is not used
+
+snmpInTooBigs OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of SNMP PDUs which were
+            delivered to the SNMP protocol entity and for
+            which the value of the error-status field was
+            `tooBig'."
+    ::= { snmp 8 }
+
+snmpInNoSuchNames OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of SNMP PDUs which were
+            delivered to the SNMP protocol entity and for
+            which the value of the error-status field was
+            `noSuchName'."
+    ::= { snmp 9 }
+
+snmpInBadValues OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of SNMP PDUs which were
+            delivered to the SNMP protocol entity and for
+            which the value of the error-status field was
+            `badValue'."
+    ::= { snmp 10 }
+
+snmpInReadOnlys OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number valid SNMP PDUs which were delivered
+            to the SNMP protocol entity and for which the value
+            of the error-status field was `readOnly'.  It should
+            be noted that it is a protocol error to generate an
+            SNMP PDU which contains the value `readOnly' in the
+            error-status field, as such this object is provided
+            as a means of detecting incorrect implementations of
+            the SNMP."
+    ::= { snmp 11 }
+
+snmpInGenErrs OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of SNMP PDUs which were delivered
+            to the SNMP protocol entity and for which the value
+            of the error-status field was `genErr'."
+    ::= { snmp 12 }
+
+snmpInTotalReqVars OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of MIB objects which have been
+            retrieved successfully by the SNMP protocol entity
+            as the result of receiving valid SNMP Get-Request
+            and Get-Next PDUs."
+    ::= { snmp 13 }
+
+snmpInTotalSetVars OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of MIB objects which have been
+            altered successfully by the SNMP protocol entity as
+            the result of receiving valid SNMP Set-Request PDUs."
+    ::= { snmp 14 }
+
+snmpInGetRequests OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of SNMP Get-Request PDUs which
+            have been accepted and processed by the SNMP
+            protocol entity."
+    ::= { snmp 15 }
+
+snmpInGetNexts OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of SNMP Get-Next PDUs which have been
+            accepted and processed by the SNMP protocol entity."
+    ::= { snmp 16 }
+
+snmpInSetRequests OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of SNMP Set-Request PDUs which
+            have been accepted and processed by the SNMP protocol
+            entity."
+    ::= { snmp 17 }
+
+snmpInGetResponses OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of SNMP Get-Response PDUs which
+            have been accepted and processed by the SNMP protocol
+            entity."
+    ::= { snmp 18 }
+
+snmpInTraps OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of SNMP Trap PDUs which have been
+            accepted and processed by the SNMP protocol entity."
+    ::= { snmp 19 }
+
+snmpOutTooBigs OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of SNMP PDUs which were generated
+            by the SNMP protocol entity and for which the value
+            of the error-status field was `tooBig.'"
+    ::= { snmp 20 }
+
+snmpOutNoSuchNames OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of SNMP PDUs which were generated
+            by the SNMP protocol entity and for which the value
+            of the error-status was `noSuchName'."
+    ::= { snmp 21 }
+
+snmpOutBadValues OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of SNMP PDUs which were generated
+            by the SNMP protocol entity and for which the value
+            of the error-status field was `badValue'."
+    ::= { snmp 22 }
+
+-- { snmp 23 } is not used
+
+snmpOutGenErrs OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of SNMP PDUs which were generated
+            by the SNMP protocol entity and for which the value
+            of the error-status field was `genErr'."
+    ::= { snmp 24 }
+
+snmpOutGetRequests OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of SNMP Get-Request PDUs which
+            have been generated by the SNMP protocol entity."
+    ::= { snmp 25 }
+
+snmpOutGetNexts OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of SNMP Get-Next PDUs which have
+            been generated by the SNMP protocol entity."
+    ::= { snmp 26 }
+
+snmpOutSetRequests OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of SNMP Set-Request PDUs which
+            have been generated by the SNMP protocol entity."
+    ::= { snmp 27 }
+
+snmpOutGetResponses OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of SNMP Get-Response PDUs which
+            have been generated by the SNMP protocol entity."
+    ::= { snmp 28 }
+
+snmpOutTraps OBJECT-TYPE
+    SYNTAX      Counter32
+    MAX-ACCESS  read-only
+    STATUS      obsolete
+    DESCRIPTION
+            "The total number of SNMP Trap PDUs which have
+            been generated by the SNMP protocol entity."
+    ::= { snmp 29 }
+
+snmpObsoleteGroup OBJECT-GROUP
+    OBJECTS { snmpOutPkts, snmpInTooBigs, snmpInNoSuchNames,
+              snmpInBadValues, snmpInReadOnlys, snmpInGenErrs,
+              snmpInTotalReqVars, snmpInTotalSetVars,
+              snmpInGetRequests, snmpInGetNexts, snmpInSetRequests,
+              snmpInGetResponses, snmpInTraps, snmpOutTooBigs,
+              snmpOutNoSuchNames, snmpOutBadValues,
+              snmpOutGenErrs, snmpOutGetRequests, snmpOutGetNexts,
+              snmpOutSetRequests, snmpOutGetResponses, snmpOutTraps
+              }
+    STATUS  obsolete
+    DESCRIPTION
+            "A collection of objects from RFC 1213 made obsolete
+            by this MIB module."
+    ::= { snmpMIBGroups 10 }
+
+END
diff --git a/files/mibs/SNMPv2-SMI.txt b/files/mibs/SNMPv2-SMI.txt
new file mode 100644
index 0000000..1c01e1d
--- /dev/null
+++ b/files/mibs/SNMPv2-SMI.txt
@@ -0,0 +1,344 @@
+SNMPv2-SMI DEFINITIONS ::= BEGIN
+
+-- the path to the root
+
+org            OBJECT IDENTIFIER ::= { iso 3 }  --  "iso" = 1
+dod            OBJECT IDENTIFIER ::= { org 6 }
+internet       OBJECT IDENTIFIER ::= { dod 1 }
+
+directory      OBJECT IDENTIFIER ::= { internet 1 }
+
+mgmt           OBJECT IDENTIFIER ::= { internet 2 }
+mib-2          OBJECT IDENTIFIER ::= { mgmt 1 }
+transmission   OBJECT IDENTIFIER ::= { mib-2 10 }
+
+experimental   OBJECT IDENTIFIER ::= { internet 3 }
+
+private        OBJECT IDENTIFIER ::= { internet 4 }
+enterprises    OBJECT IDENTIFIER ::= { private 1 }
+
+security       OBJECT IDENTIFIER ::= { internet 5 }
+
+snmpV2         OBJECT IDENTIFIER ::= { internet 6 }
+
+-- transport domains
+snmpDomains    OBJECT IDENTIFIER ::= { snmpV2 1 }
+
+-- transport proxies
+snmpProxys     OBJECT IDENTIFIER ::= { snmpV2 2 }
+
+-- module identities
+snmpModules    OBJECT IDENTIFIER ::= { snmpV2 3 }
+
+-- Extended UTCTime, to allow dates with four-digit years
+-- (Note that this definition of ExtUTCTime is not to be IMPORTed
+--  by MIB modules.)
+ExtUTCTime ::= OCTET STRING(SIZE(11 | 13))
+    -- format is YYMMDDHHMMZ or YYYYMMDDHHMMZ
+
+    --   where: YY   - last two digits of year (only years
+    --                 between 1900-1999)
+    --          YYYY - last four digits of the year (any year)
+    --          MM   - month (01 through 12)
+    --          DD   - day of month (01 through 31)
+    --          HH   - hours (00 through 23)
+    --          MM   - minutes (00 through 59)
+    --          Z    - denotes GMT (the ASCII character Z)
+    --
+    -- For example, "9502192015Z" and "199502192015Z" represent
+    -- 8:15pm GMT on 19 February 1995. Years after 1999 must use
+    -- the four digit year format. Years 1900-1999 may use the
+    -- two or four digit format.
+
+-- definitions for information modules
+
+MODULE-IDENTITY MACRO ::=
+BEGIN
+    TYPE NOTATION ::=
+                  "LAST-UPDATED" value(Update ExtUTCTime)
+                  "ORGANIZATION" Text
+                  "CONTACT-INFO" Text
+                  "DESCRIPTION" Text
+                  RevisionPart
+
+    VALUE NOTATION ::=
+                  value(VALUE OBJECT IDENTIFIER)
+
+    RevisionPart ::=
+                  Revisions
+                | empty
+    Revisions ::=
+                  Revision
+                | Revisions Revision
+    Revision ::=
+                  "REVISION" value(Update ExtUTCTime)
+                  "DESCRIPTION" Text
+
+    -- a character string as defined in section 3.1.1
+    Text ::= value(IA5String)
+END
+
+OBJECT-IDENTITY MACRO ::=
+BEGIN
+    TYPE NOTATION ::=
+                  "STATUS" Status
+                  "DESCRIPTION" Text
+
+                  ReferPart
+
+    VALUE NOTATION ::=
+                  value(VALUE OBJECT IDENTIFIER)
+
+    Status ::=
+                  "current"
+                | "deprecated"
+                | "obsolete"
+
+    ReferPart ::=
+                  "REFERENCE" Text
+                | empty
+
+    -- a character string as defined in section 3.1.1
+    Text ::= value(IA5String)
+END
+
+-- names of objects
+-- (Note that these definitions of ObjectName and NotificationName
+--  are not to be IMPORTed by MIB modules.)
+
+ObjectName ::=
+    OBJECT IDENTIFIER
+
+NotificationName ::=
+    OBJECT IDENTIFIER
+
+-- syntax of objects
+
+-- the "base types" defined here are:
+--   3 built-in ASN.1 types: INTEGER, OCTET STRING, OBJECT IDENTIFIER
+--   8 application-defined types: Integer32, IpAddress, Counter32,
+--              Gauge32, Unsigned32, TimeTicks, Opaque, and Counter64
+
+ObjectSyntax ::=
+    CHOICE {
+        simple
+            SimpleSyntax,
+          -- note that SEQUENCEs for conceptual tables and
+          -- rows are not mentioned here...
+
+        application-wide
+            ApplicationSyntax
+    }
+
+-- built-in ASN.1 types
+
+SimpleSyntax ::=
+    CHOICE {
+        -- INTEGERs with a more restrictive range
+        -- may also be used
+        integer-value               -- includes Integer32
+            INTEGER (-2147483648..2147483647),
+        -- OCTET STRINGs with a more restrictive size
+        -- may also be used
+        string-value
+            OCTET STRING (SIZE (0..65535)),
+        objectID-value
+            OBJECT IDENTIFIER
+    }
+
+-- indistinguishable from INTEGER, but never needs more than
+-- 32-bits for a two's complement representation
+Integer32 ::=
+        INTEGER (-2147483648..2147483647)
+
+-- application-wide types
+
+ApplicationSyntax ::=
+    CHOICE {
+        ipAddress-value
+            IpAddress,
+        counter-value
+            Counter32,
+        timeticks-value
+            TimeTicks,
+        arbitrary-value
+            Opaque,
+        big-counter-value
+            Counter64,
+        unsigned-integer-value  -- includes Gauge32
+            Unsigned32
+    }
+
+-- in network-byte order
+
+-- (this is a tagged type for historical reasons)
+IpAddress ::=
+    [APPLICATION 0]
+        IMPLICIT OCTET STRING (SIZE (4))
+
+-- this wraps
+Counter32 ::=
+    [APPLICATION 1]
+        IMPLICIT INTEGER (0..4294967295)
+
+-- this doesn't wrap
+Gauge32 ::=
+    [APPLICATION 2]
+        IMPLICIT INTEGER (0..4294967295)
+
+-- an unsigned 32-bit quantity
+-- indistinguishable from Gauge32
+Unsigned32 ::=
+    [APPLICATION 2]
+        IMPLICIT INTEGER (0..4294967295)
+
+-- hundredths of seconds since an epoch
+TimeTicks ::=
+    [APPLICATION 3]
+        IMPLICIT INTEGER (0..4294967295)
+
+-- for backward-compatibility only
+Opaque ::=
+    [APPLICATION 4]
+        IMPLICIT OCTET STRING
+
+-- for counters that wrap in less than one hour with only 32 bits
+Counter64 ::=
+    [APPLICATION 6]
+        IMPLICIT INTEGER (0..18446744073709551615)
+
+-- definition for objects
+
+OBJECT-TYPE MACRO ::=
+BEGIN
+    TYPE NOTATION ::=
+                  "SYNTAX" Syntax
+                  UnitsPart
+                  "MAX-ACCESS" Access
+                  "STATUS" Status
+                  "DESCRIPTION" Text
+                  ReferPart
+
+                  IndexPart
+                  DefValPart
+
+    VALUE NOTATION ::=
+                  value(VALUE ObjectName)
+
+    Syntax ::=   -- Must be one of the following:
+                       -- a base type (or its refinement),
+                       -- a textual convention (or its refinement), or
+                       -- a BITS pseudo-type
+                   type
+                | "BITS" "{" NamedBits "}"
+
+    NamedBits ::= NamedBit
+                | NamedBits "," NamedBit
+
+    NamedBit ::=  identifier "(" number ")" -- number is nonnegative
+
+    UnitsPart ::=
+                  "UNITS" Text
+                | empty
+
+    Access ::=
+                  "not-accessible"
+                | "accessible-for-notify"
+                | "read-only"
+                | "read-write"
+                | "read-create"
+
+    Status ::=
+                  "current"
+                | "deprecated"
+                | "obsolete"
+
+    ReferPart ::=
+                  "REFERENCE" Text
+                | empty
+
+    IndexPart ::=
+                  "INDEX"    "{" IndexTypes "}"
+                | "AUGMENTS" "{" Entry      "}"
+                | empty
+    IndexTypes ::=
+                  IndexType
+                | IndexTypes "," IndexType
+    IndexType ::=
+                  "IMPLIED" Index
+                | Index
+
+    Index ::=
+                    -- use the SYNTAX value of the
+                    -- correspondent OBJECT-TYPE invocation
+                  value(ObjectName)
+    Entry ::=
+                    -- use the INDEX value of the
+                    -- correspondent OBJECT-TYPE invocation
+                  value(ObjectName)
+
+    DefValPart ::= "DEFVAL" "{" Defvalue "}"
+                | empty
+
+    Defvalue ::=  -- must be valid for the type specified in
+                  -- SYNTAX clause of same OBJECT-TYPE macro
+                  value(ObjectSyntax)
+                | "{" BitsValue "}"
+
+    BitsValue ::= BitNames
+                | empty
+
+    BitNames ::=  BitName
+                | BitNames "," BitName
+
+    BitName ::= identifier
+
+    -- a character string as defined in section 3.1.1
+    Text ::= value(IA5String)
+END
+
+-- definitions for notifications
+
+NOTIFICATION-TYPE MACRO ::=
+BEGIN
+    TYPE NOTATION ::=
+                  ObjectsPart
+                  "STATUS" Status
+                  "DESCRIPTION" Text
+                  ReferPart
+
+    VALUE NOTATION ::=
+                  value(VALUE NotificationName)
+
+    ObjectsPart ::=
+                  "OBJECTS" "{" Objects "}"
+                | empty
+    Objects ::=
+                  Object
+
+                | Objects "," Object
+    Object ::=
+                  value(ObjectName)
+
+    Status ::=
+                  "current"
+                | "deprecated"
+                | "obsolete"
+
+    ReferPart ::=
+                  "REFERENCE" Text
+                | empty
+
+    -- a character string as defined in section 3.1.1
+    Text ::= value(IA5String)
+END
+
+-- definitions of administrative identifiers
+
+zeroDotZero    OBJECT-IDENTITY
+    STATUS     current
+    DESCRIPTION
+            "A value used for null identifiers."
+    ::= { 0 0 }
+
+END
diff --git a/files/mibs/SNMPv2-TC.txt b/files/mibs/SNMPv2-TC.txt
new file mode 100644
index 0000000..860bf71
--- /dev/null
+++ b/files/mibs/SNMPv2-TC.txt
@@ -0,0 +1,772 @@
+SNMPv2-TC DEFINITIONS ::= BEGIN
+
+IMPORTS
+    TimeTicks         FROM SNMPv2-SMI;
+
+-- definition of textual conventions
+
+TEXTUAL-CONVENTION MACRO ::=
+
+BEGIN
+    TYPE NOTATION ::=
+                  DisplayPart
+                  "STATUS" Status
+                  "DESCRIPTION" Text
+                  ReferPart
+                  "SYNTAX" Syntax
+
+    VALUE NOTATION ::=
+                   value(VALUE Syntax)      -- adapted ASN.1
+
+    DisplayPart ::=
+                  "DISPLAY-HINT" Text
+                | empty
+
+    Status ::=
+                  "current"
+                | "deprecated"
+                | "obsolete"
+
+    ReferPart ::=
+                  "REFERENCE" Text
+                | empty
+
+    -- a character string as defined in [2]
+    Text ::= value(IA5String)
+
+    Syntax ::=   -- Must be one of the following:
+                       -- a base type (or its refinement), or
+                       -- a BITS pseudo-type
+                  type
+                | "BITS" "{" NamedBits "}"
+
+    NamedBits ::= NamedBit
+                | NamedBits "," NamedBit
+
+    NamedBit ::=  identifier "(" number ")" -- number is nonnegative
+
+END
+
+DisplayString ::= TEXTUAL-CONVENTION
+    DISPLAY-HINT "255a"
+    STATUS       current
+    DESCRIPTION
+            "Represents textual information taken from the NVT ASCII
+
+            character set, as defined in pages 4, 10-11 of RFC 854.
+
+            To summarize RFC 854, the NVT ASCII repertoire specifies:
+
+              - the use of character codes 0-127 (decimal)
+
+              - the graphics characters (32-126) are interpreted as
+                US ASCII
+
+              - NUL, LF, CR, BEL, BS, HT, VT and FF have the special
+                meanings specified in RFC 854
+
+              - the other 25 codes have no standard interpretation
+
+              - the sequence 'CR LF' means newline
+
+              - the sequence 'CR NUL' means carriage-return
+
+              - an 'LF' not preceded by a 'CR' means moving to the
+                same column on the next line.
+
+              - the sequence 'CR x' for any x other than LF or NUL is
+                illegal.  (Note that this also means that a string may
+                end with either 'CR LF' or 'CR NUL', but not with CR.)
+
+            Any object defined using this syntax may not exceed 255
+            characters in length."
+    SYNTAX       OCTET STRING (SIZE (0..255))
+
+PhysAddress ::= TEXTUAL-CONVENTION
+    DISPLAY-HINT "1x:"
+    STATUS       current
+    DESCRIPTION
+            "Represents media- or physical-level addresses."
+    SYNTAX       OCTET STRING
+
+MacAddress ::= TEXTUAL-CONVENTION
+    DISPLAY-HINT "1x:"
+    STATUS       current
+    DESCRIPTION
+            "Represents an 802 MAC address represented in the
+            `canonical' order defined by IEEE 802.1a, i.e., as if it
+            were transmitted least significant bit first, even though
+            802.5 (in contrast to other 802.x protocols) requires MAC
+            addresses to be transmitted most significant bit first."
+    SYNTAX       OCTET STRING (SIZE (6))
+
+TruthValue ::= TEXTUAL-CONVENTION
+    STATUS       current
+    DESCRIPTION
+            "Represents a boolean value."
+    SYNTAX       INTEGER { true(1), false(2) }
+
+TestAndIncr ::= TEXTUAL-CONVENTION
+    STATUS       current
+    DESCRIPTION
+            "Represents integer-valued information used for atomic
+            operations.  When the management protocol is used to specify
+            that an object instance having this syntax is to be
+            modified, the new value supplied via the management protocol
+            must precisely match the value presently held by the
+            instance.  If not, the management protocol set operation
+            fails with an error of `inconsistentValue'.  Otherwise, if
+            the current value is the maximum value of 2^31-1 (2147483647
+            decimal), then the value held by the instance is wrapped to
+            zero; otherwise, the value held by the instance is
+            incremented by one.  (Note that regardless of whether the
+            management protocol set operation succeeds, the variable-
+            binding in the request and response PDUs are identical.)
+
+            The value of the ACCESS clause for objects having this
+            syntax is either `read-write' or `read-create'.  When an
+            instance of a columnar object having this syntax is created,
+            any value may be supplied via the management protocol.
+
+            When the network management portion of the system is re-
+            initialized, the value of every object instance having this
+            syntax must either be incremented from its value prior to
+            the re-initialization, or (if the value prior to the re-
+            initialization is unknown) be set to a pseudo-randomly
+            generated value."
+    SYNTAX       INTEGER (0..2147483647)
+
+AutonomousType ::= TEXTUAL-CONVENTION
+    STATUS       current
+    DESCRIPTION
+            "Represents an independently extensible type identification
+            value.  It may, for example, indicate a particular sub-tree
+            with further MIB definitions, or define a particular type of
+            protocol or hardware."
+    SYNTAX       OBJECT IDENTIFIER
+
+InstancePointer ::= TEXTUAL-CONVENTION
+    STATUS       obsolete
+    DESCRIPTION
+            "A pointer to either a specific instance of a MIB object or
+            a conceptual row of a MIB table in the managed device.  In
+            the latter case, by convention, it is the name of the
+            particular instance of the first accessible columnar object
+            in the conceptual row.
+
+            The two uses of this textual convention are replaced by
+            VariablePointer and RowPointer, respectively."
+    SYNTAX       OBJECT IDENTIFIER
+
+VariablePointer ::= TEXTUAL-CONVENTION
+    STATUS       current
+    DESCRIPTION
+            "A pointer to a specific object instance.  For example,
+            sysContact.0 or ifInOctets.3."
+    SYNTAX       OBJECT IDENTIFIER
+
+RowPointer ::= TEXTUAL-CONVENTION
+    STATUS       current
+    DESCRIPTION
+            "Represents a pointer to a conceptual row.  The value is the
+            name of the instance of the first accessible columnar object
+            in the conceptual row.
+
+            For example, ifIndex.3 would point to the 3rd row in the
+            ifTable (note that if ifIndex were not-accessible, then
+            ifDescr.3 would be used instead)."
+    SYNTAX       OBJECT IDENTIFIER
+
+RowStatus ::= TEXTUAL-CONVENTION
+    STATUS       current
+    DESCRIPTION
+            "The RowStatus textual convention is used to manage the
+            creation and deletion of conceptual rows, and is used as the
+            value of the SYNTAX clause for the status column of a
+            conceptual row (as described in Section 7.7.1 of [2].)
+
+            The status column has six defined values:
+
+                 - `active', which indicates that the conceptual row is
+                 available for use by the managed device;
+
+                 - `notInService', which indicates that the conceptual
+                 row exists in the agent, but is unavailable for use by
+                 the managed device (see NOTE below); 'notInService' has
+                 no implication regarding the internal consistency of
+                 the row, availability of resources, or consistency with
+                 the current state of the managed device;
+
+                 - `notReady', which indicates that the conceptual row
+                 exists in the agent, but is missing information
+                 necessary in order to be available for use by the
+                 managed device (i.e., one or more required columns in
+                 the conceptual row have not been instanciated);
+
+                 - `createAndGo', which is supplied by a management
+                 station wishing to create a new instance of a
+                 conceptual row and to have its status automatically set
+                 to active, making it available for use by the managed
+                 device;
+
+                 - `createAndWait', which is supplied by a management
+                 station wishing to create a new instance of a
+                 conceptual row (but not make it available for use by
+                 the managed device); and,
+                 - `destroy', which is supplied by a management station
+                 wishing to delete all of the instances associated with
+                 an existing conceptual row.
+
+            Whereas five of the six values (all except `notReady') may
+            be specified in a management protocol set operation, only
+            three values will be returned in response to a management
+            protocol retrieval operation:  `notReady', `notInService' or
+            `active'.  That is, when queried, an existing conceptual row
+            has only three states:  it is either available for use by
+            the managed device (the status column has value `active');
+            it is not available for use by the managed device, though
+            the agent has sufficient information to attempt to make it
+            so (the status column has value `notInService'); or, it is
+            not available for use by the managed device, and an attempt
+            to make it so would fail because the agent has insufficient
+            information (the state column has value `notReady').
+
+                                     NOTE WELL
+
+                 This textual convention may be used for a MIB table,
+                 irrespective of whether the values of that table's
+                 conceptual rows are able to be modified while it is
+                 active, or whether its conceptual rows must be taken
+                 out of service in order to be modified.  That is, it is
+                 the responsibility of the DESCRIPTION clause of the
+                 status column to specify whether the status column must
+                 not be `active' in order for the value of some other
+                 column of the same conceptual row to be modified.  If
+                 such a specification is made, affected columns may be
+                 changed by an SNMP set PDU if the RowStatus would not
+                 be equal to `active' either immediately before or after
+                 processing the PDU.  In other words, if the PDU also
+                 contained a varbind that would change the RowStatus
+                 value, the column in question may be changed if the
+                 RowStatus was not equal to `active' as the PDU was
+                 received, or if the varbind sets the status to a value
+                 other than 'active'.
+
+            Also note that whenever any elements of a row exist, the
+            RowStatus column must also exist.
+
+            To summarize the effect of having a conceptual row with a
+            status column having a SYNTAX clause value of RowStatus,
+            consider the following state diagram:
+
+                                         STATE
+              +--------------+-----------+-------------+-------------
+              |      A       |     B     |      C      |      D
+              |              |status col.|status column|
+              |status column |    is     |      is     |status column
+    ACTION    |does not exist|  notReady | notInService|  is active
+--------------+--------------+-----------+-------------+-------------
+set status    |noError    ->D|inconsist- |inconsistent-|inconsistent-
+column to     |       or     |   entValue|        Value|        Value
+createAndGo   |inconsistent- |           |             |
+              |         Value|           |             |
+--------------+--------------+-----------+-------------+-------------
+set status    |noError  see 1|inconsist- |inconsistent-|inconsistent-
+column to     |       or     |   entValue|        Value|        Value
+createAndWait |wrongValue    |           |             |
+--------------+--------------+-----------+-------------+-------------
+set status    |inconsistent- |inconsist- |noError      |noError
+column to     |         Value|   entValue|             |
+active        |              |           |             |
+              |              |     or    |             |
+              |              |           |             |
+              |              |see 2   ->D|see 8     ->D|          ->D
+--------------+--------------+-----------+-------------+-------------
+set status    |inconsistent- |inconsist- |noError      |noError   ->C
+column to     |         Value|   entValue|             |
+notInService  |              |           |             |
+              |              |     or    |             |      or
+              |              |           |             |
+              |              |see 3   ->C|          ->C|see 6
+--------------+--------------+-----------+-------------+-------------
+set status    |noError       |noError    |noError      |noError   ->A
+column to     |              |           |             |      or
+destroy       |           ->A|        ->A|          ->A|see 7
+--------------+--------------+-----------+-------------+-------------
+set any other |see 4         |noError    |noError      |see 5
+column to some|              |           |             |
+value         |              |      see 1|          ->C|          ->D
+--------------+--------------+-----------+-------------+-------------
+
+            (1) goto B or C, depending on information available to the
+            agent.
+
+            (2) if other variable bindings included in the same PDU,
+            provide values for all columns which are missing but
+            required, and all columns have acceptable values, then
+            return noError and goto D.
+
+            (3) if other variable bindings included in the same PDU,
+            provide legal values for all columns which are missing but
+            required, then return noError and goto C.
+
+            (4) at the discretion of the agent, the return value may be
+            either:
+
+                 inconsistentName:  because the agent does not choose to
+                 create such an instance when the corresponding
+                 RowStatus instance does not exist, or
+
+                 inconsistentValue:  if the supplied value is
+                 inconsistent with the state of some other MIB object's
+                 value, or
+
+                 noError: because the agent chooses to create the
+                 instance.
+
+            If noError is returned, then the instance of the status
+            column must also be created, and the new state is B or C,
+            depending on the information available to the agent.  If
+            inconsistentName or inconsistentValue is returned, the row
+            remains in state A.
+
+            (5) depending on the MIB definition for the column/table,
+            either noError or inconsistentValue may be returned.
+
+            (6) the return value can indicate one of the following
+            errors:
+
+                 wrongValue: because the agent does not support
+                 notInService (e.g., an agent which does not support
+                 createAndWait), or
+
+                 inconsistentValue: because the agent is unable to take
+                 the row out of service at this time, perhaps because it
+                 is in use and cannot be de-activated.
+
+            (7) the return value can indicate the following error:
+
+                 inconsistentValue: because the agent is unable to
+                 remove the row at this time, perhaps because it is in
+                 use and cannot be de-activated.
+
+            (8) the transition to D can fail, e.g., if the values of the
+            conceptual row are inconsistent, then the error code would
+            be inconsistentValue.
+
+            NOTE: Other processing of (this and other varbinds of) the
+            set request may result in a response other than noError
+            being returned, e.g., wrongValue, noCreation, etc.
+
+                              Conceptual Row Creation
+
+            There are four potential interactions when creating a
+            conceptual row:  selecting an instance-identifier which is
+            not in use; creating the conceptual row; initializing any
+            objects for which the agent does not supply a default; and,
+            making the conceptual row available for use by the managed
+            device.
+
+            Interaction 1: Selecting an Instance-Identifier
+
+            The algorithm used to select an instance-identifier varies
+            for each conceptual row.  In some cases, the instance-
+            identifier is semantically significant, e.g., the
+            destination address of a route, and a management station
+            selects the instance-identifier according to the semantics.
+
+            In other cases, the instance-identifier is used solely to
+            distinguish conceptual rows, and a management station
+            without specific knowledge of the conceptual row might
+            examine the instances present in order to determine an
+            unused instance-identifier.  (This approach may be used, but
+            it is often highly sub-optimal; however, it is also a
+            questionable practice for a naive management station to
+            attempt conceptual row creation.)
+
+            Alternately, the MIB module which defines the conceptual row
+            might provide one or more objects which provide assistance
+            in determining an unused instance-identifier.  For example,
+            if the conceptual row is indexed by an integer-value, then
+            an object having an integer-valued SYNTAX clause might be
+            defined for such a purpose, allowing a management station to
+            issue a management protocol retrieval operation.  In order
+            to avoid unnecessary collisions between competing management
+            stations, `adjacent' retrievals of this object should be
+            different.
+
+            Finally, the management station could select a pseudo-random
+            number to use as the index.  In the event that this index
+
+            was already in use and an inconsistentValue was returned in
+            response to the management protocol set operation, the
+            management station should simply select a new pseudo-random
+            number and retry the operation.
+
+            A MIB designer should choose between the two latter
+            algorithms based on the size of the table (and therefore the
+            efficiency of each algorithm).  For tables in which a large
+            number of entries are expected, it is recommended that a MIB
+            object be defined that returns an acceptable index for
+            creation.  For tables with small numbers of entries, it is
+            recommended that the latter pseudo-random index mechanism be
+            used.
+
+            Interaction 2: Creating the Conceptual Row
+
+            Once an unused instance-identifier has been selected, the
+            management station determines if it wishes to create and
+            activate the conceptual row in one transaction or in a
+            negotiated set of interactions.
+
+            Interaction 2a: Creating and Activating the Conceptual Row
+
+            The management station must first determine the column
+            requirements, i.e., it must determine those columns for
+            which it must or must not provide values.  Depending on the
+            complexity of the table and the management station's
+            knowledge of the agent's capabilities, this determination
+            can be made locally by the management station.  Alternately,
+            the management station issues a management protocol get
+            operation to examine all columns in the conceptual row that
+            it wishes to create.  In response, for each column, there
+            are three possible outcomes:
+
+                 - a value is returned, indicating that some other
+                 management station has already created this conceptual
+                 row.  We return to interaction 1.
+
+                 - the exception `noSuchInstance' is returned,
+                 indicating that the agent implements the object-type
+                 associated with this column, and that this column in at
+                 least one conceptual row would be accessible in the MIB
+                 view used by the retrieval were it to exist. For those
+                 columns to which the agent provides read-create access,
+                 the `noSuchInstance' exception tells the management
+                 station that it should supply a value for this column
+                 when the conceptual row is to be created.
+
+                 - the exception `noSuchObject' is returned, indicating
+                 that the agent does not implement the object-type
+                 associated with this column or that there is no
+                 conceptual row for which this column would be
+                 accessible in the MIB view used by the retrieval.  As
+                 such, the management station can not issue any
+                 management protocol set operations to create an
+                 instance of this column.
+
+            Once the column requirements have been determined, a
+            management protocol set operation is accordingly issued.
+            This operation also sets the new instance of the status
+            column to `createAndGo'.
+
+            When the agent processes the set operation, it verifies that
+            it has sufficient information to make the conceptual row
+            available for use by the managed device.  The information
+            available to the agent is provided by two sources:  the
+            management protocol set operation which creates the
+            conceptual row, and, implementation-specific defaults
+            supplied by the agent (note that an agent must provide
+            implementation-specific defaults for at least those objects
+            which it implements as read-only).  If there is sufficient
+            information available, then the conceptual row is created, a
+            `noError' response is returned, the status column is set to
+            `active', and no further interactions are necessary (i.e.,
+            interactions 3 and 4 are skipped).  If there is insufficient
+            information, then the conceptual row is not created, and the
+            set operation fails with an error of `inconsistentValue'.
+            On this error, the management station can issue a management
+            protocol retrieval operation to determine if this was
+            because it failed to specify a value for a required column,
+            or, because the selected instance of the status column
+            already existed.  In the latter case, we return to
+            interaction 1.  In the former case, the management station
+            can re-issue the set operation with the additional
+            information, or begin interaction 2 again using
+            `createAndWait' in order to negotiate creation of the
+            conceptual row.
+
+                                     NOTE WELL
+
+                 Regardless of the method used to determine the column
+                 requirements, it is possible that the management
+                 station might deem a column necessary when, in fact,
+                 the agent will not allow that particular columnar
+                 instance to be created or written.  In this case, the
+                 management protocol set operation will fail with an
+                 error such as `noCreation' or `notWritable'.  In this
+                 case, the management station decides whether it needs
+                 to be able to set a value for that particular columnar
+                 instance.  If not, the management station re-issues the
+                 management protocol set operation, but without setting
+                 a value for that particular columnar instance;
+                 otherwise, the management station aborts the row
+                 creation algorithm.
+
+            Interaction 2b: Negotiating the Creation of the Conceptual
+            Row
+
+            The management station issues a management protocol set
+            operation which sets the desired instance of the status
+            column to `createAndWait'.  If the agent is unwilling to
+            process a request of this sort, the set operation fails with
+            an error of `wrongValue'.  (As a consequence, such an agent
+            must be prepared to accept a single management protocol set
+            operation, i.e., interaction 2a above, containing all of the
+            columns indicated by its column requirements.)  Otherwise,
+            the conceptual row is created, a `noError' response is
+            returned, and the status column is immediately set to either
+            `notInService' or `notReady', depending on whether it has
+            sufficient information to (attempt to) make the conceptual
+            row available for use by the managed device.  If there is
+            sufficient information available, then the status column is
+            set to `notInService'; otherwise, if there is insufficient
+            information, then the status column is set to `notReady'.
+            Regardless, we proceed to interaction 3.
+
+            Interaction 3: Initializing non-defaulted Objects
+
+            The management station must now determine the column
+            requirements.  It issues a management protocol get operation
+            to examine all columns in the created conceptual row.  In
+            the response, for each column, there are three possible
+            outcomes:
+
+                 - a value is returned, indicating that the agent
+                 implements the object-type associated with this column
+                 and had sufficient information to provide a value.  For
+                 those columns to which the agent provides read-create
+                 access (and for which the agent allows their values to
+                 be changed after their creation), a value return tells
+                 the management station that it may issue additional
+                 management protocol set operations, if it desires, in
+                 order to change the value associated with this column.
+
+                 - the exception `noSuchInstance' is returned,
+                 indicating that the agent implements the object-type
+                 associated with this column, and that this column in at
+                 least one conceptual row would be accessible in the MIB
+                 view used by the retrieval were it to exist. However,
+                 the agent does not have sufficient information to
+                 provide a value, and until a value is provided, the
+                 conceptual row may not be made available for use by the
+                 managed device.  For those columns to which the agent
+                 provides read-create access, the `noSuchInstance'
+                 exception tells the management station that it must
+                 issue additional management protocol set operations, in
+                 order to provide a value associated with this column.
+
+                 - the exception `noSuchObject' is returned, indicating
+                 that the agent does not implement the object-type
+                 associated with this column or that there is no
+                 conceptual row for which this column would be
+                 accessible in the MIB view used by the retrieval.  As
+                 such, the management station can not issue any
+                 management protocol set operations to create an
+                 instance of this column.
+
+            If the value associated with the status column is
+            `notReady', then the management station must first deal with
+            all `noSuchInstance' columns, if any.  Having done so, the
+            value of the status column becomes `notInService', and we
+            proceed to interaction 4.
+
+            Interaction 4: Making the Conceptual Row Available
+
+            Once the management station is satisfied with the values
+            associated with the columns of the conceptual row, it issues
+            a management protocol set operation to set the status column
+            to `active'.  If the agent has sufficient information to
+            make the conceptual row available for use by the managed
+            device, the management protocol set operation succeeds (a
+            `noError' response is returned).  Otherwise, the management
+            protocol set operation fails with an error of
+            `inconsistentValue'.
+
+                                     NOTE WELL
+
+                 A conceptual row having a status column with value
+                 `notInService' or `notReady' is unavailable to the
+                 managed device.  As such, it is possible for the
+                 managed device to create its own instances during the
+                 time between the management protocol set operation
+                 which sets the status column to `createAndWait' and the
+                 management protocol set operation which sets the status
+                 column to `active'.  In this case, when the management
+                 protocol set operation is issued to set the status
+                 column to `active', the values held in the agent
+                 supersede those used by the managed device.
+
+            If the management station is prevented from setting the
+            status column to `active' (e.g., due to management station
+            or network failure) the conceptual row will be left in the
+            `notInService' or `notReady' state, consuming resources
+            indefinitely.  The agent must detect conceptual rows that
+            have been in either state for an abnormally long period of
+            time and remove them.  It is the responsibility of the
+            DESCRIPTION clause of the status column to indicate what an
+            abnormally long period of time would be.  This period of
+            time should be long enough to allow for human response time
+            (including `think time') between the creation of the
+            conceptual row and the setting of the status to `active'.
+            In the absence of such information in the DESCRIPTION
+            clause, it is suggested that this period be approximately 5
+            minutes in length.  This removal action applies not only to
+            newly-created rows, but also to previously active rows which
+            are set to, and left in, the notInService state for a
+            prolonged period exceeding that which is considered normal
+            for such a conceptual row.
+
+                             Conceptual Row Suspension
+
+            When a conceptual row is `active', the management station
+            may issue a management protocol set operation which sets the
+            instance of the status column to `notInService'.  If the
+            agent is unwilling to do so, the set operation fails with an
+            error of `wrongValue' or `inconsistentValue'.  Otherwise,
+            the conceptual row is taken out of service, and a `noError'
+            response is returned.  It is the responsibility of the
+            DESCRIPTION clause of the status column to indicate under
+            what circumstances the status column should be taken out of
+            service (e.g., in order for the value of some other column
+            of the same conceptual row to be modified).
+
+                              Conceptual Row Deletion
+
+            For deletion of conceptual rows, a management protocol set
+            operation is issued which sets the instance of the status
+            column to `destroy'.  This request may be made regardless of
+            the current value of the status column (e.g., it is possible
+            to delete conceptual rows which are either `notReady',
+            `notInService' or `active'.)  If the operation succeeds,
+            then all instances associated with the conceptual row are
+            immediately removed."
+    SYNTAX       INTEGER {
+                     -- the following two values are states:
+                     -- these values may be read or written
+                     active(1),
+                     notInService(2),
+                     -- the following value is a state:
+                     -- this value may be read, but not written
+                     notReady(3),
+                     -- the following three values are
+                     -- actions: these values may be written,
+                     --   but are never read
+                     createAndGo(4),
+                     createAndWait(5),
+                     destroy(6)
+                 }
+
+TimeStamp ::= TEXTUAL-CONVENTION
+    STATUS       current
+    DESCRIPTION
+            "The value of the sysUpTime object at which a specific
+            occurrence happened.  The specific occurrence must be
+
+            defined in the description of any object defined using this
+            type.
+
+            If sysUpTime is reset to zero as a result of a re-
+            initialization of the network management (sub)system, then
+            the values of all TimeStamp objects are also reset.
+            However, after approximately 497 days without a re-
+            initialization, the sysUpTime object will reach 2^^32-1 and
+            then increment around to zero; in this case, existing values
+            of TimeStamp objects do not change.  This can lead to
+            ambiguities in the value of TimeStamp objects."
+    SYNTAX       TimeTicks
+
+TimeInterval ::= TEXTUAL-CONVENTION
+    STATUS       current
+    DESCRIPTION
+            "A period of time, measured in units of 0.01 seconds."
+    SYNTAX       INTEGER (0..2147483647)
+
+DateAndTime ::= TEXTUAL-CONVENTION
+    DISPLAY-HINT "2d-1d-1d,1d:1d:1d.1d,1a1d:1d"
+    STATUS       current
+    DESCRIPTION
+            "A date-time specification.
+
+            field  octets  contents                  range
+            -----  ------  --------                  -----
+              1      1-2   year*                     0..65536
+              2       3    month                     1..12
+              3       4    day                       1..31
+              4       5    hour                      0..23
+              5       6    minutes                   0..59
+              6       7    seconds                   0..60
+                           (use 60 for leap-second)
+              7       8    deci-seconds              0..9
+              8       9    direction from UTC        '+' / '-'
+              9      10    hours from UTC*           0..13
+             10      11    minutes from UTC          0..59
+
+            * Notes:
+            - the value of year is in network-byte order
+            - daylight saving time in New Zealand is +13
+
+            For example, Tuesday May 26, 1992 at 1:30:15 PM EDT would be
+            displayed as:
+
+                             1992-5-26,13:30:15.0,-4:0
+
+            Note that if only local time is known, then timezone
+            information (fields 8-10) is not present."
+    SYNTAX       OCTET STRING (SIZE (8 | 11))
+
+StorageType ::= TEXTUAL-CONVENTION
+    STATUS       current
+    DESCRIPTION
+            "Describes the memory realization of a conceptual row.  A
+            row which is volatile(2) is lost upon reboot.  A row which
+            is either nonVolatile(3), permanent(4) or readOnly(5), is
+            backed up by stable storage.  A row which is permanent(4)
+            can be changed but not deleted.  A row which is readOnly(5)
+            cannot be changed nor deleted.
+
+            If the value of an object with this syntax is either
+            permanent(4) or readOnly(5), it cannot be written.
+            Conversely, if the value is either other(1), volatile(2) or
+            nonVolatile(3), it cannot be modified to be permanent(4) or
+            readOnly(5).  (All illegal modifications result in a
+            'wrongValue' error.)
+
+            Every usage of this textual convention is required to
+            specify the columnar objects which a permanent(4) row must
+            at a minimum allow to be writable."
+    SYNTAX       INTEGER {
+                     other(1),       -- eh?
+                     volatile(2),    -- e.g., in RAM
+                     nonVolatile(3), -- e.g., in NVRAM
+                     permanent(4),   -- e.g., partially in ROM
+                     readOnly(5)     -- e.g., completely in ROM
+                 }
+
+TDomain ::= TEXTUAL-CONVENTION
+    STATUS       current
+    DESCRIPTION
+          "Denotes a kind of transport service.
+
+          Some possible values, such as snmpUDPDomain, are defined in
+          the SNMPv2-TM MIB module.  Other possible values are defined
+          in other MIB modules."
+    REFERENCE    "The SNMPv2-TM MIB module is defined in RFC 1906."
+    SYNTAX       OBJECT IDENTIFIER
+
+TAddress ::= TEXTUAL-CONVENTION
+    STATUS       current
+    DESCRIPTION
+          "Denotes a transport service address.
+
+          A TAddress value is always interpreted within the context of a
+          TDomain value.  Thus, each definition of a TDomain value must
+          be accompanied by a definition of a textual convention for use
+          with that TDomain.  Some possible textual conventions, such as
+          SnmpUDPAddress for snmpUDPDomain, are defined in the SNMPv2-TM
+          MIB module.  Other possible textual conventions are defined in
+          other MIB modules."
+    REFERENCE    "The SNMPv2-TM MIB module is defined in RFC 1906."
+    SYNTAX       OCTET STRING (SIZE (1..255))
+
+END
diff --git a/files/send-host-trap b/files/send-host-trap
new file mode 100755
index 0000000..e1d0d50
--- /dev/null
+++ b/files/send-host-trap
@@ -0,0 +1,11 @@
+#!/bin/bash
+
+# Arguments:
+# $1 = Management Station
+# $2 = Community String
+# $3 = host_name
+# $4 = HostStatID A number that corresponds to the current state of the host: 0=UP, 1=DOWN, 2=UNREACHABLE.
+# $5 = HOSTOUTPUT The first line of text output from the last host check (i.e. "Ping OK").
+#
+/usr/bin/snmptrap -v 2c -c "$2" "$1" "" NAGIOS-NOTIFY-MIB::nHostEvent nHostname s "$3" nHostStateID i "$4" nHostOutput s "$5"
+
diff --git a/files/send-service-trap b/files/send-service-trap
new file mode 100755
index 0000000..3659089
--- /dev/null
+++ b/files/send-service-trap
@@ -0,0 +1,15 @@
+#!/bin/bash
+
+# Arguments:
+# $1 = Management Station
+# $2 = Community String
+# $3 = host_name
+# $4 = service_description (Description of the service)
+# $5 = return_code (An integer that determines the state
+#       of the service check, 0=OK, 1=WARNING, 2=CRITICAL,
+#       3=UNKNOWN).
+# $6 = plugin_output (A text string that should be used
+#       as the plugin output for the service check)
+#
+/usr/bin/snmptrap -v 2c -c "$2" "$1" "" NAGIOS-NOTIFY-MIB::nSvcEvent nSvcHostname s "$3" nSvcDesc s "$4" nSvcStateID i "$5" nSvcOutput s "$6"
+
diff --git a/hooks/install b/hooks/install
index f002e46..4e65d8d 100755
--- a/hooks/install
+++ b/hooks/install
@@ -67,6 +67,15 @@ dpkg-statoverride --update --add nagios www-data 2710 /var/lib/nagios3/rw || :
 dpkg-statoverride --update --add nagios nagios 751 /var/lib/nagios3 || :
 service nagios3 start
 
+# install files needed for sending snmp traps functionality
+cp -v $CHARM_DIR/files/mibs/NAGIOS-NOTIFY-MIB /usr/share/snmp/mibs/
+cp -v $CHARM_DIR/files/mibs/NAGIOS-ROOT-MIB /usr/share/snmp/mibs/
+cp -v $CHARM_DIR/files/mibs/SNMPv2-MIB.txt /usr/share/snmp/mibs/
+cp -v $CHARM_DIR/files/mibs/SNMPv2-SMI.txt /usr/share/snmp/mibs/
+cp -v $CHARM_DIR/files/mibs/SNMPv2-TC.txt /usr/share/snmp/mibs/
+cp -v $CHARM_DIR/files/send-host-trap /usr/local/bin/
+cp -v $CHARM_DIR/files/send-service-trap /usr/local/bin/
+
 # For the admin interface
 open-port 80
 
diff --git a/hooks/templates/traps.tmpl b/hooks/templates/traps.tmpl
new file mode 100644
index 0000000..d1874e6
--- /dev/null
+++ b/hooks/templates/traps.tmpl
@@ -0,0 +1,22 @@
+
+define command{
+        command_name send-service-trap
+        command_line /usr/local/bin/send-service-trap {{ send_traps_to }} public "$HOSTNAME$" "$SERVICEDESC$" $SERVICESTATEID$ "$SERVICEOUTPUT$"
+}
+
+define command{
+        command_name send-host-trap
+        command_line /usr/local/bin/send-host-trap {{ send_traps_to }} public "$HOSTNAME$" $HOSTSTATEID$ "$HOSTOUTPUT$"
+}
+
+define contact{
+        contact_name                    managementstation
+        alias                           Management Station
+        service_notification_period     24x7
+        host_notification_period        24x7
+        service_notification_options    w,u,c,r,f,s
+        host_notification_options       d,u,r,f,s
+        service_notification_commands   send-service-trap
+        host_notification_commands      send-host-trap
+}
+
diff --git a/hooks/upgrade-charm b/hooks/upgrade-charm
index a80743b..bbbb8ac 100755
--- a/hooks/upgrade-charm
+++ b/hooks/upgrade-charm
@@ -35,11 +35,16 @@ cert_domain = hookenv.unit_get('public-address')
 nagios_cfg = "/etc/nagios3/nagios.cfg"
 nagios_cgi_cfg = "/etc/nagios3/cgi.cfg"
 pagerduty_cfg = "/etc/nagios3/conf.d/pagerduty_nagios.cfg"
+traps_cfg = "/etc/nagios3/conf.d/traps.cfg"
 pagerduty_cron = "/etc/cron.d/nagios-pagerduty-flush"
 password = hookenv.config('password')
 ro_password = hookenv.config('ro-password')
 nagiosadmin = hookenv.config('nagiosadmin') or 'nagiosadmin'
+contactgroup_members = hookenv.config("contactgroup-members")
 
+# this global var will collect contactgroup members that must be forced
+# it will be changed by functions
+forced_contactgroup_members = []
 
 # Checks the charm relations for legacy relations
 # Inserts warnings into the log about legacy relations, as they will be removed
@@ -113,6 +118,8 @@ def enable_livestatus_config():
 
 
 def enable_pagerduty_config():
+    global  forced_contactgroup_members
+
     if enable_pagerduty:
         hookenv.log("Pagerduty is enabled")
         fetch.apt_update()
@@ -161,11 +168,42 @@ def enable_pagerduty_config():
             os.remove(pagerduty_cron)
 
     # Update contacts for admin
-    contactgroup_members = hookenv.config("contactgroup-members")
     if enable_pagerduty:
         # avoid duplicates
         if "pagerduty" not in contactgroup_members:
-            contactgroup_members += ", pagerduty"
+            forced_contactgroup_members.append('pagerduty')
+
+def enable_traps_config():
+    global forced_contactgroup_members
+
+    send_traps_to = hookenv.config('send_traps_to')
+
+    if not send_traps_to:
+        if os.path.isfile(traps_cfg):
+            os.remove(traps_cfg)
+        hookenv.log("Send traps feature is disabled")
+        return
+
+    hookenv.log("Send traps feature is enabled, target address is %s" % send_traps_to)
+
+    if "managementstation" not in contactgroup_members:
+        forced_contactgroup_members.append('managementstation')
+
+    template_values = { 'send_traps_to': send_traps_to }
+
+    with open('hooks/templates/traps.tmpl','r') as f:
+        templateDef = f.read()
+
+    t = Template(templateDef)
+    with open(traps_cfg, 'w') as f:
+        f.write(t.render(template_values))
+
+
+def update_contacts():
+    resulting_members = contactgroup_members
+
+    if forced_contactgroup_members:
+        resulting_members = resulting_members + ',' + ','.join(forced_contactgroup_members)
 
     template_values = {'admin_service_notification_period': hookenv.config('admin_service_notification_period'),
                        'admin_host_notification_period': hookenv.config('admin_host_notification_period'),
@@ -174,7 +212,7 @@ def enable_pagerduty_config():
                        'admin_service_notification_commands': hookenv.config('admin_service_notification_commands'),
                        'admin_host_notification_commands': hookenv.config('admin_host_notification_commands'),
                        'admin_email': hookenv.config('admin_email'),
-                       'contactgroup_members': contactgroup_members}
+                       'contactgroup_members': resulting_members}
 
     with open('hooks/templates/contacts-cfg.tmpl', 'r') as f:
         templateDef = f.read()
@@ -294,6 +332,7 @@ def update_config():
 
     with open('hooks/templates/localhost_nagios2.cfg.tmpl', 'r') as f:
         templateDef = f.read()
+
     t = Template(templateDef)
     with open('/etc/nagios3/conf.d/localhost_nagios2.cfg', 'w') as f:
         f.write(t.render(template_values))
@@ -374,11 +413,13 @@ write_extra_config()
 update_config()
 enable_livestatus_config()
 enable_pagerduty_config()
+enable_traps_config()
 if ssl_configured():
     enable_ssl()
 update_apache()
 update_localhost()
 update_cgi_config()
+update_contacts()
 update_password('nagiosro', ro_password)
 if password:
     update_password(nagiosadmin, password)

Follow ups