Forum Discussion
Don_Noel_23994
Nimbostratus
Nov 30, 2005DNS Monitor
I am load balancing DNS servers and the UDP monitor does not effectively test DNS server health. How would I write a custom monitor that could do a DNS query that would determine the nodes health?
Thank You.
- Colin_Walker_12Historic F5 AccountWe here at DevCentral are the folks who work on the API (iControl) and the onboard packet inspector/scripting language (iRules). If you have a question about building iControl apps or writing iRules, this is the place for you.
- Don_Noel_23994
Nimbostratus
I will try that route. - Nicolas_BerthieHistoric F5 AccountI made an external monitor in perl. It sends a DNS request to a specific hostname. Hope this will help.
! /usr/bin/perl -w hostname my ($domain)= "www.yahoo.fr"; my (@addrlist,$name,$altnames,$addrtype,$len,$packaddr); my ($ip); hostname resolution if (!(($name, $altnames, $addrtype, $len, @addrlist) = gethostbyname ($domain))) { return "DOWN"; } else { return "UP"; }
- Does that really work in testing the DNS service on the specified nodes? It looks to me like it makes a call to gethostbyname to resolve "www.yahoo.fr". This will use the local systems nameserver to resolve the name. So from what I can see this only tests your local DNS server as well as yahoo.fr's.
- kykong_107132
Nimbostratus
Hi All,
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects