ybiC has asked for the wisdom of the Perl Monks concerning the following question:
and Net::DNS::Resolver provides this example of querying multiple nameservers :use Net::DNS; $res = new Net::DNS::Resolver; $query = $res->search("foo.bar.com"); if ($query) { foreach $rr ($query->answer) { next unless $rr->type eq "A"; print $rr->address, "\n"; } } else { print "query failed: ", $res->errorstring, "\n"; }
My humble question to the master monks - how do I inject the Net::DNS::Resolver snippet into the Net::DNS query ?$res->nameservers("192.168.1.1", "192.168.2.2", "192.168.3.3");
|
---|
Replies are listed 'Best First'. | |
---|---|
DNS Querying Multiple Resolvers in Series - Re: OO
by lhoward (Vicar) on Jun 30, 2000 at 02:05 UTC | |
Re: OO (alternate, not multiple, nameservers)
by ybiC (Prior) on Jun 30, 2000 at 03:23 UTC |