check_http.sh

Simple bash script using curl to check a website.
It works on HTTP and HTTPS.
Requirement: curl
Usage ./check_http.sh
Example:
./check_http.sh ‘http://oglobo.globo.com’ oglobo 1
OK – Site oglobo.globo.com key oglobo

check_ftp.php

Nagios plugin to verify a FTP site, by uploading a file and testing the time it takes.
check_ftp.php
#!/usr/bin/php
< ?php // Script to connect to a FTP site and Upload a file, return the time it took and compare to WARN and CRIT values // Formated for Nagios usage // Use a test user for the FTP as it could be simple to get this password // I use a 5mb file, created by using: dd bs=1024 count=5120 skip=5120 if=/dev/sda of=file.tst // by Felipe Ferreira http://felipeferreira.net if($argc < 7){ echo "nPlease provide args “;
echo “nExample: n check_ftp.php ftp.check.com anonymous pass /folder1010/ /tmp/file.txt 4