I have done this using curl with a grep statement then wc -l. Basically if I don't see something in the HTML that I expect, I make the DNS change.
If you want to just check if port 80 is up, you can use nc (netcat). I think nc -u hostname 80 | grep successful | wc -l By using curl, you are testing more. For an example, you could have a php error that renders a site incorrectly but port 80 will still be up. I just use a simple if else statement. Let me know if you need my example script. I use this all the time. I use zenloadbalancer which uses pound. It would be nice if bind was installed by default for a true f5 GTM type of feature. I also have scripts that will modify the zone record on both bind nameservers that can be executed with arguments. Sent from my iPhone > On Apr 8, 2014, at 9:29 AM, "Robert Segall" <[email protected]> wrote: > > On Mon, 7 Apr 2014 16:16:31 -0400 > Brad Allison <[email protected]> wrote: > >> I'm setting up a automatic DNS failover for pound to flip DNS to point to >> my second pound server if the first one dies. >> >> I don't want to a URL through pound because then I'm really testing the web >> service under pound and not really pound. >> >> I could do a simple TCP port check against pound, but I was hoping for >> something better. >> >> Is it possible to configure pound to serve a single local URL for the >> purposes of monitoring pound? >> >> -brad > > You could request something that doesn't match any rule - you'll get the > error message (standard or custom). > -- > Robert Segall > Apsis GmbH > Postfach, Uetikon am See, CH-8707 > Tel: +41-32-512 30 19 > > -- > To unsubscribe send an email with subject unsubscribe to [email protected]. > Please contact [email protected] for questions. On Mon, 7 Apr 2014 16:16:31 -0400 Brad Allison <[email protected]> wrote: > I'm setting up a automatic DNS failover for pound to flip DNS to point to > my second pound server if the first one dies. > > I don't want to a URL through pound because then I'm really testing the web > service under pound and not really pound. > > I could do a simple TCP port check against pound, but I was hoping for > something better. > > Is it possible to configure pound to serve a single local URL for the > purposes of monitoring pound? > > -brad You could request something that doesn't match any rule - you'll get the error message (standard or custom). -- Robert Segall Apsis GmbH Postfach, Uetikon am See, CH-8707 Tel: +41-32-512 30 19 -- To unsubscribe send an email with subject unsubscribe to [email protected]. Please contact [email protected] for questions.
