Web Hosting Talk







View Full Version : Self-Uptime Monitoring Script


Fizzadar
04-20-2008, 06:37 AM
OK, when a network or server goes down, no one can access it from the internet, fine, but it also means the server can't access the internet (unless the problem is incoming traffic only, is that possible?). So, in theory, servers can monitor their own 'web' uptime, by setting up a script which attempts to access google.com or some place which is going to be up all the time, records the result, and voila, a self-uptime-monitor. Just have a cron run the script every x mins.

Would it work?

Nick Charlton
04-20-2008, 08:26 AM
Assuming you didn't have some obscure DNS setup then yes, I can't see why it wouldn't work. And Google with their redundancy make a good example to ping.

I think the truth will be in the testing with this one though.

Nick

Fizzadar
04-20-2008, 10:04 AM
Yeah, it'll have to be tested, I'll probably get working on something soon, might be something people would want/use. I just see $5/month as a pointless expense when it comes to uptime monitoring (since status pages are really simple anyway, and I'm working on one of those too).

HiVelocity
04-20-2008, 10:21 AM
you could give www.hyperspin.com a try. www.alertra.com is another good one.

Fizzadar
04-20-2008, 10:33 AM
you could give www.hyperspin.com (http://www.hyperspin.com) a try. www.alertra.com (http://www.alertra.com) is another good one.

I've used hyperspin, and heard good things about alerta, but this is really about a custom solution that is not only free, but self hosted ;)

HiVelocity
04-20-2008, 10:48 AM
I've used hyperspin, and heard good things about alerta, but this is really about a custom solution that is not only free, but self hosted ;)

It is always best to have an outside source monitoring your server , as it gives a better view of how the outside world sees your server.

VN-Ken
04-20-2008, 02:30 PM
You can still have a server off site and monitor your network though. Why pay someone else to give you a limited number of IP's/hostnames to test when you can spend $20/mo or so on a cheap VPS for unlimited. This is something we're trying to do however have not found the right software.

Dawson
04-20-2008, 02:35 PM
You can still have a server off site and monitor your network though. Why pay someone else to give you a limited number of IP's/hostnames to test when you can spend $20/mo or so on a cheap VPS for unlimited. This is something we're trying to do however have not found the right software.

The right software? Nagios!

Panopta
04-20-2008, 03:16 PM
It is always best to have an outside source monitoring your server , as it gives a better view of how the outside world sees your server.

This also gives you the benefit of being alerted when your server is inaccessible. The original poster's idea should work fine for measuring uptime, but if their server loses network connectivity, there's no way for it to alert anyone which means you won't know about the outage until someone happens to notice the problem which could take quite a while. In the meantime, you're losing customers who will go elsewhere.

Also, don't forget that you want to test the response of all of the services that your running locally. Being able to access google.com doesn't tell you anything about whether Apache is working correctly on your server.

Panopta
04-20-2008, 03:22 PM
Why pay someone else to give you a limited number of IP's/hostnames to test when you can spend $20/mo or so on a cheap VPS for unlimited.

For the same reason you'd pay someone else for server management or other outsourced services. Yes, you can setup Nagios yourself on a VPS somewhere, but many people don't want to worry about installing, configuring and upgrading software, maintaining multiple monitoring locations for redundancy, working with SMS gateway providers, etc.

Of course, I might be a bit biased ;)

VN-Ken
04-20-2008, 06:01 PM
Your viewpoint is also correct, but I am talking about companies that have 100+ servers which you provide monitoring services for. It would be highly ineffective to get a service like SiteUptime at that point - at least in my opinion.

Usually companies with a few dozen servers have someone on staff who can handle te tasks of installing, configuring and upgrading as well.

So I guess our viewpoints are different. I had the viewpoint of a service provider while it sounds like yours was in the perspective of an individual. Even for an individual it may be more cost effective to spend that $20-30/mo on a server, do Nagios and also experiment with other softwares. But that depends on that particular users knowledge I suppose.

Panopta
04-20-2008, 10:23 PM
Ken, I agree with you - it really depends on what you've got in terms of resources, knowledge and what you need in terms of monitoring.

There are some advantages to going with a monitoring provider tho - being able to provide independent availability results to your customers helps strengthen claims of reliability. Also as an aside, our service is designed to handle hosting environments with large numbers of servers. Feel free to PM me if you're interested in more details.

plumsauce
04-21-2008, 02:59 AM
Even for an individual it may be more cost effective to spend that $20-30/mo on a server, do Nagios and also experiment with other softwares.

Um, no.

First, there are providers who offer unlimited domains/servers for free. Therefore, these providers will always beat self hosting.

Second, a serious provider lives and breathes monitoring and understands exactly what the results mean. This is contrasted to someone treating monitoring as a side job.

linux-tech
04-21-2008, 01:15 PM
Um, no.

First, there are providers who offer unlimited domains/servers for free. Therefore, these providers will always beat self hosting.

There is no such thing as unlimited. Each server has a cost, each server takes resources from the networks involved, and takes resources from the monitoring servers.

Anyone offering 'unlimited' anything is lying to the end customer when they say this. Unlimited is a farce.


Second, a serious provider lives and breathes monitoring and understands exactly what the results mean. This is contrasted to someone treating monitoring as a side job.
Here, I agree
A true monitoring service has multiple servers, vps' (for checks), in multiple locations. They can look @ their own tests and tell you exactly WHEN services were down and when they were up, which services, for how long, how long it took to get to those services, and so much more.

There's a lot more to monitoring than nagios and vps' . Of course, the person trying to suggest the OP go with a VPS is trying to SELL them a VPS, so, that's not a surprise there ;)

uberhostNET
04-21-2008, 02:05 PM
There is no such thing as unlimited.


What is the finite number of domains that one of your clients may host on a given server that you sell?

Dawson
04-21-2008, 02:09 PM
What is the finite number of domains that one of your clients may host on a given server that you sell?

( {Free Space} / {Amount of bytes that domain records occupies} ) - {Overhead}.

linux-tech
04-21-2008, 02:15 PM
What is the finite number of domains that one of your clients may host on a given server that you sell?

That's already been answered, and a very good answer at that.
Each individual server would need to have that taken into account. There is, however, absolutely no such thing as unlimited. Time, domains, emails (emails are debatable), databases, all of this ties into resource usage, which of course is limited, so, again, there is no unlimited.

Now, a direct answer to your question? That is 100% up to the client if they're after a 'managed server'.

uberhostNET
04-21-2008, 02:19 PM
That's already been answered, and a very good answer at that.
Each individual server would need to have that taken into account. There is, however, absolutely no such thing as unlimited. Time, domains, emails (emails are debatable), databases, all of this ties into resource usage, which of course is limited, so, again, there is no unlimited.

Now, a direct answer to your question? That is 100% up to the client if they're after a 'managed server'.

As it is 100% up to the VPS, reseller, or shared hosted customer how they use their resources.

Do you picket "All you can eat" restaurants if they don't let you take the whole platter of prime rib to your table?

Dawson
04-21-2008, 02:21 PM
Nothing is unlimited in this industry, Linux-Tech is completely correct in this regard. Any company who advertises otherwise, in my opinion - is just asking for trouble.

Now, if domains were just being "parked" - and a server was doing nothing else, you could certainly host a fair few.

linux-tech
04-21-2008, 02:22 PM
That's different. There are policies and limits there, and the term is 'all you can eat'. I don't really think there's many people that can 'eat' an entire platter of prime rib themselves ;) .

Unlimited means just that 'no limits', and it's a farce.

uberhostNET
04-21-2008, 02:43 PM
Unlimited means just that 'no limits', and it's a farce.

Unlimited simply means unrestricted, not infinite. What phrase would please you? "No preset limit"? This has worked for American Express, who promises the same. If you offered shared hosting, would you put a hard limit on every service, or use different verbiage?

Dawson
04-21-2008, 02:45 PM
UberHost - the phrase you are looking for is "unmetered".

uberhostNET
04-21-2008, 02:48 PM
UberHost - the phrase you are looking for is "unmetered".

Fumi: No, it is not. ;)

linux-tech
04-21-2008, 02:49 PM
Unlimited simply means unrestricted, not infinite.

Actually, it does not, and the american dictionary (http://dictionary.reference.com/browse/unlimited) agrees.

The first term in the unlimited definition:

not limited


Now, to be fair, the whole term:

1. not limited; unrestricted; unconfined: unlimited trade.
2. boundless; infinite; vast: the unlimited skies.
3. without any qualification or exception; unconditional.


Unlimited: without limits, without restrictions.

Everything in this industry has limits, restrictions and confines. If you're on a 10m/s pipe, you're 'limited' (restricted, confined) to that 10m/s . If you've got a 200g hard drive, you're LIMITED to that 200g. If you've got 4g ram, you're LIMITED to that 4g. Everything in this industry has limits. Unlimited is merely a term cooked up by the con artists in this industry to suggest that there are no limits, when there actually are. That term is a farce.


Unmetered is different, and that's only appropriate for bandwidth.

uberhostNET
04-21-2008, 02:58 PM
And what is the definition for "unmetered" as it would apply to domain names, email accounts, FTP accounts, etc? And as I asked before, linux-tech, what limits would you impose on such features if you were to offer shared hosting?

linux-tech
04-21-2008, 03:24 PM
Unmetered doesn't apply to what you listed, so it can't be done. Advertising 'unlimited' resources is just a farce, but that's not what this thread is about. Please, try to stay on topic.

As far as what limits I, personally would put on them, that's not something I'm going to answer. I don't now, or never will, compete with my clients. The answer to that question though has already been given, more effectively than I can. This isn't something that can be set for one server and forgotten about, it takes calculation and time to do this.

Now, can we get back to the topic of monitoring, rather than you trying to distract with your rants of 'unlimited is legitimate'?

uberhostNET
04-21-2008, 03:46 PM
you could give www.hyperspin.com a try. www.alertra.com is another good one.

Absolutely. I've had good experiences with both. :agree: