This resource model monitors the output of the command HTTPCheck_sh
| Internal Name | IBMDirector_HTTPCheck |
| Descriptive Name | HTTPCheck_sh Monitor |
| Platforms | w32-ix86 |
| Category | WizGenRM |
| Category Description | Wizard Generated Resource Models |
| Cycle Time | 300 |
| Version | 1.0 |
| Internal Name | Ev_HTTPCheck_sh_ScriptResult_matches | ||||||||||
| Descriptive Name | CheckHTTP | ||||||||||
| Description | This event is Generated when the IBM Director Agent Web Server goes Down. | ||||||||||
| Message | The IBM Director HTTP Server is Down. | ||||||||||
| Numeric Attributes | |||||||||||
| String Attributes |
| ||||||||||
| Keys | |||||||||||
| Occurrences | 1 | ||||||||||
| Holes | 0 | ||||||||||
| Clearing Event | TRUE | ||||||||||
| Send to TEC | TRUE | ||||||||||
| Send to TBSM | FALSE | ||||||||||
| Severity | CRITICAL | ||||||||||
| |||||||||||
| Internal Name | Descriptive Name | Description | Default Value |
|---|
| Internal Name | Descriptive Name | Description | Type | Values |
|---|---|---|---|---|
| Par_ScriptResult_eqs | ScriptResult matching values | When the property ScriptResult is equal to one of the values of this parameter the event Ev_HTTPCheck_sh_ScriptResult_matches is generated | STRING LIST |
|
| Context | Resource | Keys | Numeric Attributes | String Attributes |
|---|
//''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
// IBM Tivoli Monitoring
// Decision Tree script
//
// This file has been generated by IBM Tivoli Monitoring Workbench
//
// 02/27/2003 12:49:59
//'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
var hTableScriptResult;
var flagNotFirstRun = 0;
// This function is used to define the settings of the resource model
// It is called only once, when the resource model is started.
// Don't modify remarks containing tags like <<....>> ... <<\...>>
// You can write additional initializing code in this function if required.
function SetDefaultConfiguration (Svc)
{
// General info section
//<<GENERAL_INFO>>
Svc.SetModelName ("IBMDirector_HTTPCheck");
Svc.SetProfileName ("618613890");
Svc.SetCycleTime (300);
//<<\GENERAL_INFO>>
// Thresholds section
//<<THRESHOLDS_INFO>>
//<<\THRESHOLDS_INFO>>
// Parameters section
//<<PARAMETERS_INFO>>
Svc.DefineStrParameter ("Par_ScriptResult_eqs", "down");
//<<\PARAMETERS_INFO>>
// Dynamic model section
//<<DATA_INFO>>
//<<\DATA_INFO>>
// Event definition section
//<<EVENTS_INFO>>
Svc.DefineEvent ("Ev_HTTPCheck_sh_ScriptResult_matches", "", "prev_value,value,relation_delta,ScriptResult");
//<<\EVENTS_INFO>>
// Logging definition section
//<<LOGGING_INFO>>
//<<\LOGGING_INFO>>
// Place your additional intializing code below
return (0);
}
// This function is called by the DM For Windows Analyzer after that
// the resource model default settings have been overridden
// It is called only once, when the resource model is started.
// You can write additional initializing code in this function if required
// to use the thresholds and parameters values
function Init(Svc)
{
hTableScriptResult = Svc.CreateMap();
return (0);
}
// This function contains the monitoring algorithm
// It is called ciclically after a cycle time has elapsed
// Implement the the monitoring code here
function VisitTree(Svc)
{
var curScriptResult;
var hashKey;
var found;
var OldScriptResult;
var hPropTable;
var ProbeArgCount;
var ProbeArgIdx;
var ParamCount;
var ParamIdx;
var Different;
hPropTable = Svc.CreateMap();
//Implementation for the monitor ScriptResult
Svc.RemoveMapAll(hPropTable);
hashKey = "ScriptResult";
curScriptResult = Svc.Shell ("HTTPCheck.sh");
Svc.SetMapStrElement(hPropTable,"ScriptResult",curScriptResult);
found = Svc.ExistsMapElement(hTableScriptResult, hashKey);
if (found)
OldScriptResult = Svc.GetMapStrValue(hTableScriptResult, hashKey);
else
OldScriptResult = "";
Svc.SetMapStrElement(hPropTable,"OldScriptResult",OldScriptResult);
Svc.SetMapStrElement(hPropTable,"prev_value", OldScriptResult);
Svc.SetMapStrElement(hPropTable,"value", curScriptResult);
Svc.SetMapStrElement(hPropTable,"relation_delta","");
ParamCount = Svc.GetStrParameterCount("Par_ScriptResult_eqs");
for (ParamIdx = 0; ParamIdx < ParamCount; ParamIdx++) {
if ((curScriptResult.toLowerCase() + "") == (Svc.GetStrParameter("Par_ScriptResult_eqs", ParamIdx).toLowerCase())) {
Svc.SendEventEx ("Ev_HTTPCheck_sh_ScriptResult_matches",hPropTable);
}
}
Svc.SetMapStrElement(hTableScriptResult, hashKey, curScriptResult);
Svc.DestroyMap(hPropTable);
return (0);
}
|
| All |
|
| w32-ix86 |
This Html document has been generated by IBM Tivoli Monitoring Workbench