Huntland Services Ltd

Tel: +44 (0)1392-490518
Fax: +44 (0)1392-428003
Enquiries@huntland.co.uk

Sampled Numeric Data Statistics Portfolio

Back Download The Scripts

 

Introduction

Why is my database full of performance monitor data?  Which managed node is the one that is generating all this data?  Which Object.counter.instance is the biggest source for performance monitor data?  What Object.counter.instances are being monitored on my IIS box?

The following scripts list sampled numeric data from various angles to provide a view on how many are being created and by whom.  The output will be displayed on screen and also written to a TXT file or CSV file suitable for use with Excel.  The result includes over what period of time (measured in hours) the sampled data has been collected and what is the oldest date/time for each type of sample. 

Because of the size of the output these scripts should only be run from a Command Prompt using CSCRIPT.  You will need to specify the following paramaters:

  1. myMomSqlServer - The name of the server hosting the MOM Onepoint Database
  2. outputFile - the full path and name of the file to be used for output.  Specifying a CSV extension will produce a comma separated output suitable for use with Excel.  All other extensions will produce a Text output suitable for other reporting tools.
  3. myServer - the name of the computer to which you want to limit the results.  For example specify 'Server1' if you are only interested in alerts/events for that machine.   SQL wild cards are valid so that Server% or just % widen the scope of eligible machines to be included.

In all cases your account must have access to the MOM SQL Server and at least read access to the Onepoint database.  Windows Security ('Integrated') is assumed.

If your database is many gigabytes in size then you can expect a delay while the query runs.  Each script has two commented timeout values controlling the maximum connection time and the maximum time to run a command.  By default these are set low and may have to be increased for larger databases.

 

1. SNDSource.vbs

Purpose:   To list which object.counter.instances are being sampled from each machine, how many have been collected and over what period in hours.

Syntax:     cscript  SNDSource .vbs   myMomSqlServer     C:\temp\SNDSource.txt     myServer

Result:

Computer Source Total # Span Hrs Oldest
myServer System.Processor Queue Length. 1126 24 22/07/2002 15:00:00
myServer Process.% Processor Time.sqlservr 1006 24 22/07/2002 15:00:00
myServer SMTP Server.Remote Retry Queue Length._Total 561 24 22/07/2002 15:00:00

 

 

 

 

2. SNDSource_Summary.vbs

Purpose:  To list which object.counter.instances are being sampled , how many have been collected and over what period in hours for all machines.

Syntax:   cscript   SNDSource_Summary.vbs   myMomSqlServer     C:\temp\eventSourceSummary.txt    

Result:

Source Total # Span Hrs Oldest
Memory.Page Reads/sec. 23456 456 22/07/2002 15:00:00
Memory.Page Writes/sec. 5647 34 22/07/2002 15:00:00
Process.% Processor Time.OnePointService 3456 45 22/07/2002 15:00:00

 

 

 

 

3. SNDSummary.vbs

Purpose:   A summary of all sampled numeric data

Syntax:  cscript   SNDSummary.vbs   myMomSqlServer     C:\temp\eventSummary.txt 

Result:

Computer Total #
Server23 32678
Server12 15345
Server99 2435

 

 

 

 

 

Please accept these scripts as is.  Any feedback will be gratefully received at Debug@Huntland.co.uk