Results 1 to 4 of 4
  1. #1
    Join Date
    Jan 2007
    Location
    Bay Area, CA
    Posts
    143

    A good site monitoring script?

    A good site monitoring script?

  2. #2
    Try hotscripts.com, there are dozens to play with.
    edgedirector.com
    managed dns global failover and load balance (gslb)
    exactstate.com
    uptime report for webhostingtalk.com

  3. #3
    Join Date
    Apr 2002
    Location
    Hollywood, CA
    Posts
    3,046
    If you're look for a monitoring system I suggest Nagios. It's robust, scalable, free and can monitor literally anything.

    If you need a simple pass/fail script I suggest rolling your own. Take for instance the script I have provided below. It makes a http request to google and searches for the term 'Feeling Lucky'. If these the term doesn't exist on the page, the page is obviously not loading and an email is dispatched! It took me about 2-3 minutes to write and test. If anyone does use this script make sure you're using the proper path to sendmail

    Code:
    #!/usr/bin/perl
    
    use warnings;
    use strict;
    
    use LWP::Simple;
    use Sys::Hostname;
    
    my $hostname = hostname();
    my $to       = "user\@gmail.com";
    my $from     = "root\@$hostname";
    my $subject  = "HTTP on $hostname is down";
    my $message  = "fix me asap";
    my $url      = "http://google.com";
    
    my $content = get $url;
        die "Couldn't get $url" unless defined $content;
    
    if ( $content =~ m/Feeling Lucky/i ) {
        # Do nohingl p
    }
    else {
        print "error\n";
        &alert( $to, $from, $subject, $message );
    }
    
    sub alert {
        my ( $to, $from, $subject, $message ) = @_;
        my $sendmail = '/usr/sbin/sendmail';
    
        open(MAIL, "|$sendmail -oi -t");
    
        print MAIL "From: $from\n";
        print MAIL "To: $to\n";
        print MAIL "Subject: $subject\n\n";
        print MAIL "$message\n";
    
        close(MAIL);
    }

  4. #4
    Join Date
    Aug 2006
    Location
    Mumbai, India
    Posts
    94
    If you are looking for a remotely hosted script then - http://www.host-tracker.com/ is a good service.
    Specialists in Kayako Applications - Implementation, Development, Customizations & Premium Support
    Website: http://www.supportskins.com | Twitter: @supportskins | Facebook: supportskins

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •