On Oct 21, 2005, at 10:09 AM, Alexander Lamb wrote:

>>
>>
>>
>>> I am implementing a very simple script to ping web servers or
>>> services (to monitor how our environment is functionning).
>>>
>>>
>>
>> This thread seems to thrashing around a bit.
>>
>> By what criteria do you establish how your environment is  
>> functioning? Once you know that you can look into how to monitor  
>> those criteria alone and no others.
>>
>> A 'ping' is really testing the network and web server  
>> responsiveness (assuming the ping task is simple). You can't  
>> separate those. Establish a base line and compare to that. I'd  
>> think that if the network or server is stalling for any reason  
>> you'd like to know, and when comparing to a base line you have a  
>> chance of detecting that.
>>
>> The application responsiveness is probably best measured on the  
>> server by the application itself, possibly by recording the time  
>> between first touch on the app through to the close or flush of  
>> the socket. You'd have to ask the application to report on this.
>>
>>
>>
> Yes, you are right. This ping is really only the first building  
> block (but you can't imagine how many times we had problems because  
> of a simple Apache server which didn't restart gracefully at  
> midnight:-) at the same time the apps were running fine... just  
> nobody could get to them, which is rather annoying in a hospital.

I most certainly can imagine it... well, actually, I can rely on  
memory :-)

>
> That's why we have a monitoring system which monitors not only the  
> Apache servers but some key WebServices as well. To monitor  
> WebServices we either do some kind of dummy search (e.g. give me  
> the list of patients in this unit) or implement a specific service  
> which shall test a few things and reply with some information about  
> speed of the transaction and other things.
>
> What you saw in my post is the first block ( a simple HTTP Ping  
> probe) for the new system I wish to develop in Ruby. I will then  
> have a sort of master process which will consolidate the states of  
> the various probes and display (to be defined: how) the situation.  
> If some situation seems critical, then some kind of alert will be  
> escalated.

Okay, still, I'd *strongly* suggest the baseline thing (given my  
experience) and establishing service levels too. I've written several  
monitoring systems, some quite large, sometimes while on a team that  
built the hardware to run the monitoring system. Comparison to  
expectations or historical records, while tricky to get working at  
first, works very well in the end.

>
> This brings to another question (sorry I am a beginner in Ruby): is  
> there a rule engine available in Ruby where you could express rules  
> a bit like with Jess in Java?

I don't know personally. But your rules might be overly 'crisp' and  
so not very stable (think chaos, and tipping points). I'd have a look  
around for a simple fuzzy reasoning system (an unfortunate phrase :-)  
but *way* more stable.

Cheers,
Bob

>
> Thanks
>
> Alex
>
>
>

----
Bob Hutchison          -- blogs at <http://www.recursive.ca/hutch/>
Recursive Design Inc.  -- <http://www.recursive.ca/>
Raconteur              -- <http://www.raconteur.info/>