Blog Splash

Monitoring Site Uptime

by Kerido Wednesday, February 10, 2010 8:46 AM

I'd rather not mention the name of my hosting provider, but I'm definitely dissatisfied with their service. In the beginning of February I started monitoring website uptime.

The idea behind the tool I've written is simple. The program runs as a service on a dedicated machine and periodically queries a known resource on the website. The query intervals are adjustable. Currently I've specified them as follows:

  • every 30 minutes if the resource has been successfully accessed;
  • every 5 minutes if the resource cannot be accessed.

This is actually the main reason I decided to write my own tool – you only get hourly monitoring from free services. If you want more frequent pings, you have to pay. And I'm just too old school to pay for this.

If the resource on the website cannot be reached, the tool tries to determine if the server on which it is running, has no connection. To do so, it queries a so called trusted URL. Finally, the site is considered down only if the trusted URL can be reached.

Another concept I put into the tool is analysis. The program automatically displays downtime intervals: start time, end time and duration. Given the sum of these intervals, I calculate total uptime, total downtime, and most importantly, relative uptime. I can perform this kind of analysis for various periods.

After a couple of weeks of monitoring I guess, the hosting provider is somewhat cheating with numbers. They promise 99.9% uptime. My tool shows a more truthful figure.

It makes sense to monitor your website uptime because you need to know what you're paying for. If anybody is interested, I'll probably publish the source code some time later.

Comments

7/4/2011 4:50:12 AM #

Claudia

Kerido I would like to suggest you a good monitoring services website which which offers high quality monitoring services with over 15 monitoring locations across the globe to control uptime and latency for your website and/or server solution.It  performs 50 different checks using some of the most superior internet protocols like HTTP, IMAP, POP3 etc..and let  you to know if your website or server is down . Monitor Scout will send out a signal to check if the user is connected to the internet. If not, an email or SMS alert will be sent out. The alert messages will be sent immediately when the system detects a fault on the user's website or server.

Claudia India