Search Exchange

Search All Sites

Nagios Live Webinars

Let our experts show you how Nagios can help your organization.

Contact Us

Phone: 1-888-NAGIOS-1
Email: sales@nagios.com

Login

Remember Me

Directory Tree

Simple Proxy Check

Rating
3 votes
Favoured:
0
Hits
132547
Files:
FileDescription
check_proxy.shcheck_proxy.sh
Nagios CSP

Meet The New Nagios Core Services Platform

Built on over 25 years of monitoring experience, the Nagios Core Services Platform provides insightful monitoring dashboards, time-saving monitoring wizards, and unmatched ease of use. Use it for free indefinitely.

Monitoring Made Magically Better

  • Nagios Core on Overdrive
  • Powerful Monitoring Dashboards
  • Time-Saving Configuration Wizards
  • Open Source Powered Monitoring On Steroids
  • And So Much More!
This is a very simple proxy script that tests functionality from the user's point of view (does the page come through as expected versus a direct download). It should work with any proxy server that is compatible with wget.
This script assumes your nagios server has the ability to load a test URL directly and is allowed to use your proxy without a username and password (you should be able to modify it to use a username and password).

To make use of this script, you will need the following binaries:

- wget
- bc
- date
- diff

Once you've downloaded the file to your plugins directory, here's a sample command definition for your Nagios configuration files:

define command{
command_name check_proxy
command_line $USER1$/check_proxy http://$HOSTADDRESS$:8080/
}

The port is still hard coded currently, but it works with Squid 2.5 at least. YMMV
Reviews (2)
Hi,

I have checked this and it worked fine, since we have a proxy user name and password, i have modified the script by adding the proxyuser and proxypassword to wget, this you can do it in two ways, either you hard code the user name and password or pass it as a argument
byVictor, August 9, 2010
This a good funcionality.
But im confuse about the command line.

command_line $USER1$/check_proxy http://$HOSTADDRESS$:8080/

in the http://$HOSTADDRESS$:8080 will i put the address of my Proxy ?

How i add more proxys to test ?!