This page (revision-1) was last changed on 29-Nov-2024 16:16 by admin

Only authorized users are allowed to rename pages.

Only authorized users are allowed to delete pages.

Page revision history

Version Date Modified Size Author Changes ... Change note

Page References

Incoming links Outgoing links

Version management

Difference between version and

At line 1 added 86 lines
!!! Overview
This script will scrape eDirectory 8.7.x [Imonitor] Continuity statistics.
Tool written by [John Johnson] when we worked together.
!! [getimon.pl|ToolToScrapeImonitorContinuityStats/getimon.pl]
%%warning
Use at your own risk! [Standard Disclaimer] We are never responsible!
This is OLD code that has not been tested or used in several years.
%%
Typically, you would use the [Sadmin] user.This script will scrape eDirectory 8.7.x [Imonitor] Continuity statistics, such as:
*Partition Root
*Errors
*Last Successful Sync.
*Maximum Ring Delta
*Replica's Perishable Data Delta
It will read an input file that specifies the servers and partition roots to collect data from, and print comma-delimited results to standard output.
!Setup
This script should be portable to any platform that implements Perl 5.x. It has been tested on Windows and Linux. There are several modules that may need to be installed prior to use:
*Time::Format
*LWP
*HTML::TableContentParser
These modules may be installed with PPM (Windows) or CPAN:
{{{
perl -MCPAN -e shell
}}}
!Usage
Open a command line in the directory that you placed the attached files.
{{{
Usage: getimon.pl [-f inputfile]
}}}
If the -f option is not specified, the script will look for a file in the default directory named:
{{{
imonLst.txt
}}}
!Input file format
{{{
host:domain:iMonitor port:iMonitor user:iMonitor password:T=treename
}}}
!Output file format
The field headings are as follows. Comma delimited:
{{{
yyyy-mm-dd hh:mm,Partition Root,Partition or Host,Query Status,Errors,Last Successful Sync.,Maximum Ring Delta,Replica's Perishable Data Delta
}}}
Tab delimited:
{{{
yyyy-mm-dd hh:mm Partition Root Partition or Host Query Status Errors Last Successful Sync. Maximum Ring Delta Replica's Perishable Data Delta
}}}
!Example execution
This example uses an input file in a subdirectory under the ndsuser home directory:
{{{
[ndsuser@host] $ $HOME/bin/getimon.pl -f bin/imonLst.txt
2005-09-06 13:20,"T=TREE1",.TREE1.,OK,0,0:00:20,0:00:30,0:00:00
2005-09-06 13:20,"T=TREE2",.TREE2.,OK,0,0:00:51,0:00:41,0:00:41
2005-09-06 13:20,"T=TREE3",.TREE3.,OK,0,0:00:09,0:00:27,0:00:09
2005-09-06 13:20,"T=TREE4",.TREE4.,OK,0,0:54:05,0:00:00,312784:25:57
}}}
!Scheduling with CRON
This will run the script to collect data every 5 minutes:
{{{
#
# Gather iMonitor Continuity stats
#
00,05,10,15,20,25,30,35,40,45,50,55 * * * * $HOME/bin/getimon.pl -f bin/imonLst.txt >> $HOME/imon.log 2>&1
}}}
!! More Information
There might be more information for this subject on one of the following:
[{ReferringPagesPlugin before='*' after='\n' }]