25.01.2015 Views

Caché Monitoring Guide - InterSystems Documentation

Caché Monitoring Guide - InterSystems Documentation

Caché Monitoring Guide - InterSystems Documentation

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>Monitoring</strong> <strong>Caché</strong> Using SNMP<br />

Example of Creating a User MIB<br />

To create the SNMP MIB, run the MonitorTools.SNMP:CreateMIB method from the %SYS namespace. See the<br />

MonitorTools.SNMP class documentation for details.<br />

The input parameters for the method are similar to the following:<br />

CreateMIB("MyApp","USER",99990,1,"mycorp","myapp","mc","MC-MYAPP","Unknown",1)<br />

Important:<br />

Do not use 99990 as the Enterprise ID for production; each organization should register with the IANA<br />

for their own ID.<br />

USER>zn "%SYS"<br />

%SYS>Do ##class(MonitorTools.SNMP).CreateMIB("MyApp","USER",99990,1,"mycorp",<br />

"myapp","mc","MC-MYAPP","Unknown",1)<br />

Create SNMP structure for Application - MyApp<br />

Group - MyTable<br />

Counter1 = Integer<br />

Counter2 = Integer<br />

Status = String<br />

Create MIB file for MyApp<br />

Generate table MyTable<br />

Add object Counter1<br />

Add object Counter2<br />

Add object Status<br />

%SYS><br />

This creates the MC-MYAPP.MIB file in your default directory (install-dir\Mgr\User), which you can load into your SNMP<br />

management application.<br />

Note:<br />

You may need to restart the SNMP master agent and the <strong>Caché</strong> ^SNMP service on your system before each recognizes<br />

this MIB.<br />

--<br />

-- MIB file generated for mcMyApp product.<br />

--<br />

-- Sep 16, 2008<br />

--<br />

MC-MYAPP DEFINITIONS ::= BEGIN<br />

IMPORTS<br />

MODULE-IDENTITY, OBJECT-TYPE, NOTIFICATION-TYPE,<br />

Counter32, Gauge32, Integer32<br />

FROM SNMPv2-SMI<br />

DisplayString<br />

FROM SNMPv2-TC<br />

enterprises<br />

FROM RFC1155-SMI<br />

cacheSysIndex<br />

FROM ISC-CACHE;<br />

mcMyApp MODULE-IDENTITY<br />

LAST-UPDATED "200809161700Z"<br />

ORGANIZATION "mycorp"<br />

CONTACT-INFO "<br />

Unknown"<br />

DESCRIPTION ""<br />

::= { mycorp 1 }<br />

mycorp OBJECT IDENTIFIER ::= { enterprises 16563 }<br />

myappObjects OBJECT IDENTIFIER ::= { mcMyApp 1 }<br />

--<br />

116 <strong>Caché</strong> <strong>Monitoring</strong> <strong>Guide</strong>

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!