[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
DHCP server monitor
- To: <hobbit (at) hswn.dk>
- Subject: DHCP server monitor
- From: "Savigni ing. Roberto" <r.savigni (at) ausl.fe.it>
- Date: Fri, 8 Jul 2005 10:14:19 +0200
- Disposition-notification-to: "Savigni ing. Roberto" <r.savigni@ausl.fe.it>
- Importance: Normal
Good Morning.
I've installed Hobbit on a BB server.
It is able to monitor everything I need except DHCP daemon.
The DHCP server is the same of BB server in the main location, while
I've 3 more DHCP servers in remote locations (each running bb-client).
I've tried to use the external program that make the use of DHCPING
(bb-dhcp) that I've found on deadcat.net, but this is not able to
dhcping -s localhost.
In BBSERVER I've added the following line in $BBHOME/bin/bb-network.sh
to test it and it works
------------------------------------------------------------------------
--------------------------------------------------------------------
# DHCP support...Ray DeJean ( <mailto:ray (at) selu.edu> ray (at) selu.edu)
# most of this code is stolen from
# Frank T. Kujawski < <mailto:frank (at) bluegrass.net> frank (at) bluegrass.net>
who added DNS support
# requires nmap tool in /usr/local/bin
dhcp ) # echo "looking for dhcp server"
/usr/bin/nmap -sU -p 67 ${HOSTIP} | $GREP "closed dhcpserver" >
/dev/null 2>&1
if test "$?" = "0"
then
LINE="DHCP Server on ${FULLNAME} down"
echo "$NONETPAGE" | $GREP "dhcp" > /dev/null 2>&1
if test $? = "1" # NOT FOUND - PAGE
then
COLOR="red"
else
COLOR="yellow"
LINE="$LINE - configured not to page"
fi
else
COLOR="green"
LINE="DHCP Server OK"
fi
$BB $BBDISP "status ${MACHINE}.dhcp $COLOR `date` $LINE"
;;
------------------------------------------------------------------------
----------------------------------------------------------------
Any suggestion on how I can made the same check with Hobbit?
Thanks in advance
Roberto