Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> How to adding custom Oracle counters to PerfMon on NT.

How to adding custom Oracle counters to PerfMon on NT.

From: <seahorse3419_at_my-dejanews.com>
Date: Thu, 27 Aug 1998 22:25:29 GMT
Message-ID: <6s4mco$h4j$1@nnrp1.dejanews.com>


Add the following entries to the bottom of the following Oracle files :-

c:\orant\dbs\opctrnm.ini

// Datafile object - TEST COUNTER

ORA7_TEST_OBJ_009_NAME=Oracle7 Test Counter (Users) ORA7_TEST_OBJ_009_HELP=Test counter to show how many users are logged in.

// Datafile object - Users connected

ORA7_TEST_OBJ_USERS_009_NAME=users
ORA7_TEST_OBJ_USERS_009_HELP=Number of users logged in.

c:\orant\dbs\opctrnm.h

// ORA7_TEST_OBJ

#define ORA7_TEST_OBJ 100
#define ORA7_TEST_OBJ_USERS 102

c:\orant\dbs\perf.ora

OBJ_START = TEST

OBJ_INDEX_OFFSET = 100
OBJ_DETAIL_LEVEL = PERF_DETAIL_NOVICE
OBJ_SQL =
OBJ_INSTANCES = 0
OBJ_INST_DATA_TYPE =
OBJ_INST_DATA_LEN = 0
OBJ_INST_PARENT_INDEX_OFFSET = 0
OBJ_CTR_NUMBER = 1

OBJ_COUNTER_START = users
OBJ_COUNTER_INDEX_OFFSET = 102
OBJ_COUNTER_SCALE = 0
OBJ_COUNTER_LEVEL = PERF_DETAIL_NOVICE
OBJ_COUNTER_TYPE = PERF_COUNTER_RAWCOUNT
OBJ_COUNTER_SIZE = 4

OBJ_COUNTER_DATA_OFFSET = 4
OBJ_COUNTER_SQL = select count(username) from v$session where username is not null
OBJ_COUNTER_EXT_ORACLE_DATA_TYPE = INTEGER_TYPE
OBJ_COUNTER_EXT_ORACLE_DATA_LEN = 4
OBJ_COUNTER_END = users

OBJ_END = TEST then unload the old counters by typing :-

c:\ unlodctr Oracle7

and reload them using

c:\ lodctr opctrnm.ini

et voila, you should have a new objecct called 'Oracle 7 Test Counter (Users)' I've tried this on Oracle 7.3.4 and it works ok.

Anyone have any good docs about what can be put into the various OBJ_ fields in perf.ora?

Cheers,
Jason.

-----== Posted via Deja News, The Leader in Internet Discussion ==----- http://www.dejanews.com/rg_mkgrp.xp Create Your Own Free Member Forum Received on Thu Aug 27 1998 - 17:25:29 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US