On Tue, Jul 26, 2011 at 11:19 AM, Paul Heinlein <[email protected]> wrote:

> On Tue, 26 Jul 2011, wes wrote:
>
> > Does anyone know of a tool that can monitor DNS replies and notify on
> > success/failure?
> >
> > Basically, I want to find out the moment a DNS server (that I do not
> > control) has updated.
>
> Assuming the DNS server in question has an IPv4 address of 12.13.14.15
> and the updated address of the host in question is 100.101.102.103,
> then
>
> #!/bin/sh
> DNSSRV=12.13.14.15
> GOODIP=100.101.102.103
> YOURHOST=your.hostname.com
> MSG="Your DNS Record is Up to Date"
> while true; do
>   if test $(dig +short @$DNSSRV $YOURHOST) = $GOODIP; then
>     echo "$MSG" | /bin/mail -s "$MSG" [email protected]
>     break
>   fi
>   sleep 120
> done
>
> --
> Paul "I love the smell of /bin/sh in the morning" Heinlein
>
>
thanks for doing all my work for me :)

-wes
_______________________________________________
PLUG mailing list
[email protected]
http://lists.pdxlinux.org/mailman/listinfo/plug

Reply via email to