We woudn't like our domain to expire, and having our domain bought by an ciberspeculator (also bad-known as "cibersquatters"), asking us 1.000$ for it, when it's actually worth 20 (I've lived that situation with a personal domain name of myself).
It's not a big deal, after all registrars always warn users in advance, giving you every chance for renewal (that's their interest). But... what if the email address you configured that day, is not active any more? What if the new boss secretary mistake it with spam, and ignore it (real case)? What if the company is so big that no one knows who is reading that email address?
To make sure we are up-to-date with our domains, I've created a nagios plugin, named "check_domain". It's simple (if you look at the code, you'll see there's more lines parsing parameters than doing things ), but it covers our needs, and warns you when the domain name is near to expire.
In the full article ("read more") you can see the code, and a downloadable file.
#!/bin/bash
PROGPATH=`echo $0 | /bin/sed -e 's,[\\/][^\\/][^\\/]*$,,'`
. $PROGPATH/utils.sh
# Default values (days):
critical=7
warning=30
# Parse arguments
args=`getopt -o hd:w:c:P: --long help,domain:,warning:,critical:,path: -u -n $0 -- "$@"`
[ $? != 0 ] && echo "$0: Could not parse arguments" && echo "Usage: $0 -h | -d <domain> [-c <critical>] [-w <warning>]" && exit
set -- $args
while true ; do
case "$1" in
-c|--critical) critical=$2;shift 2;;
-w|--warning) warning=$2;shift 2;;
-d|--domain) domain=$2;shift 2;;
-P|--path) whoispath=$2;shift 2;;
-h|--help) echo "check_domain - v1.01"
echo "Copyright (c) 2005 Tom�s N��ez Lirola <tnunez@criptos.com> under GPL License"
echo "This plugin checks the expiration date of a domain name."
echo ""
echo "Usage: $0 -h | -d <domain> [-c <critical>] [-w <warning>]"
echo "NOTE: -d must be specified"
echo ""
echo "Options:"
echo "-h"
echo " Print detailed help"
echo "-d"
echo " Domain name to check"
echo "-w"
echo " Response time to result in warning status (days)"
echo "-c"
echo " Response time to result in critical status (days)"
echo ""
echo "This plugin will use whois service to get the expiration date for the domain name. "
echo "Example:"
echo " $0 -d domain.tld -w 30 -c 10"
echo ""
exit;;
--) shift; break;;
*) echo "Internal error!" ; exit 1 ;;
esac
done
[ -z $domain ] && echo "UNKNOWN - There is no domain name to check" && exit $STATE_UNKNOWN
# Looking for whois binary
if [ -z $whoispath ]; then
type whois &> /dev/null || error="yes"
[ ! -z $error ] && echo "UNKNOWN - Unable to find whois binary in your path. Is it installed? Please specify path." && exit $STATE_UNKNOWN
else
[ ! -x "$whoispath/whois" ] && echo "UNKNOWN - Unable to find whois binary, you specified an incorrect path" && exit $STATE_UNKNOWN
fi
# Calculate days until expiration
expiration=`whois $domain |grep "Expiration Date:"| awk -F"Date:" '{print $2}'|cut -f 1`
expseconds=`date +%s --date="$expiration"`
nowseconds=`date +%s`
((diffseconds=expseconds-nowseconds))
expdays=$((diffseconds/86400))
# Trigger alarms if applicable
[ -z "$expiration" ] && echo "UNKNOWN - Domain doesn't exist or no WHOIS server available." && exit $STATE_UNKNOWN
[ $expdays -lt 0 ] && echo "CRITICAL - Domain expired on $expiration" && exit $STATE_CRITICAL
[ $expdays -lt $critical ] && echo "CRITICAL - Domain will expire in $expdays days" && exit $STATE_CRITICAL
[ $expdays -lt $warning ]&& echo "WARNING - Domain will expire in $expdays days" && exit $STATE_WARNING
# No alarms? Ok, everything is right.
echo "OK - Domain will expire in $expdays days"
exit $STATE_OK
Comments
silver tiffany
Tiffany not only explored the various jewelry processes of the time, but also branched out into new metals, such as platinum, which at the time was considered very hard to manipulate.It seems to be the case that unusual colorations appealed to Tiffany, like the opal.He also preferred gemstones that were either opaque or translucent. Turquoise, jade, carnelian, lapis, moonstones, and opals were all chosen for their ability to filter light. Emphasis based on color was very prevalent in his works.Silver TiffanyHe devoted hi s first year of jewelry making to mainly a focus towards forms and techniques, and only began to really put a collection together once he was satisfied with the fruits of his labor.Once Tiffany and Co.’s began to manufacture his jewelry, there was a marked evolution in his pieces. His earlier pieces went from being made in a “hand-wrought” looking manner, to a much more symmetrical and stylized fashion. There was a great variety of jewelry that was produced during the 26 years that Louis Tiffany’s enameling and jewelry division was in operation at Tiffany & Co. It has been estimated that nearly 5,500 pieces were produced during that time, an impressive amount considering the detail and craftsmanship in each piece.He was produced the same high-quality artisanship that was very prized during the Arts and Crafts movement.
ghd straighteners purple
LYQLL20100906 They ghd hair straighteners have had some success, but the militants have proved a resilient enemy. Pakistan ghd straighteners uk army jets and helicopters targeted militant hide-outs in two ghd iv styler border regions on Tuesday and Wednesday, killing 60 people identified pink ghd straightners as insurgents or their family members, including children, said security ghd straighteners purple officials and a witness. There was no independent confirmation of the casualties chi turbo flat iron because the area is too dangerous for outsiders to visit. The raids Tuesday instyler curling irons took place in several villages in Teerah Valley in the Khyber region and Babyliss Flat Irons the officials said. http://www.ustylers.com/