Downloading the check_url.pl plugin

  1. Change to the nagios plugin directory:
    cd /usr/local/nagios/libexec/
  2. Download the check_url.pl plugin:
    sudo wget -O check_url.pl "https://exchange.nagios.org/components/com_mtree/attachment.php?link_id=1395&cf_id=24"
  3. Make the plugin executable:
    sudo chmod 755 check_url.pl
  4. Update the file check_url.pl to replace all tmp_ with /tmp/tmp_ text (i.e. if you are using vi for editing using the following:)
    %s#tmp_#/tmp/tmp_#g

Testing The Plugin

/usr/local/nagios/libexec/check_url.pl https://www.google.com

Expect to see the following output:

OK: 200  OK

Displaying the Help

/usr/local/nagios/libexec/check_url.pl -h