Digging to the final IP

Darcy Kevin (FCA) kevin.darcy at fcagroup.com
Tue Oct 21 23:18:50 UTC 2014


We have people on this list who are incapable of programming simple text extraction in *at*least*one*language*? Really?

No-one said a _scripting_ language had to be used. Feel free to use C (with "sharp" or "plusplus", if you wish), or Pascal, or Smalltalk, or LISP, or Fortran, or S/370 Assembler. Whatever floats your boat. Whatever doesn't look like "line-noise" to you, nor has a requirement of "stunning brilliance" to use. Feel free to format it in pretty ways (if the language allows you to do that) and/or comment it liberally.

(Personally, I'd probably use Perl with the Net::DNS module, but that's only because I've written about a million of those scripts and so wouldn't have to think too hard about it).

												- Kevin

-----Original Message-----
From: bind-users-bounces at lists.isc.org [mailto:bind-users-bounces at lists.isc.org] On Behalf Of Warren Kumari
Sent: Tuesday, October 21, 2014 3:07 PM
To: Mark Andrews
Cc: bind-users at isc.org
Subject: Re: Digging to the final IP

On Mon, Oct 20, 2014 at 1:19 PM, Mark Andrews <marka at isc.org> wrote:
>
> Why do we need to have a option to dig to massage the results into 
> every possible different form?
>
> dig A $name | awk '$0 ~ /status/ && $0 !~ /status: NOERROR,/ {
>                         sub(",", "", $6 ); print $6; x=1
>                    }
>                    $4 == "A" { print $5; x=1 }
>                    END { if (!x) print "TIMEOUT" }'


Because, not everyone is as stunningly brilliant as you?

To a non-zero population of this list the above looks like line-noise...

W

>
> Mark
>
>
> In message <54451077.8030907 at imperial.ac.uk>, Phil Mayers writes:
>> On 20/10/14 14:22, Frank Bulk (iname.com) wrote:
>> > We=92re using this in a bash shell script.  I don=92t think 
>> > there=92s a n=
>> ative
>> > shell command to get the IP, so I=92ll use a mixture of host and 
>> > dig as necessary.
>>
>> If your system has it, try "getent" e.g.
>>
>> getent ahosts hostname
>> _______________________________________________
>> Please visit https://lists.isc.org/mailman/listinfo/bind-users to 
>> unsubscri= be from this list
>>
>> bind-users mailing list
>> bind-users at lists.isc.org
>> https://lists.isc.org/mailman/listinfo/bind-users
> --
> Mark Andrews, ISC
> 1 Seymour St., Dundas Valley, NSW 2117, Australia
> PHONE: +61 2 9871 4742                 INTERNET: marka at isc.org
> _______________________________________________
> Please visit https://lists.isc.org/mailman/listinfo/bind-users to 
> unsubscribe from this list
>
> bind-users mailing list
> bind-users at lists.isc.org
> https://lists.isc.org/mailman/listinfo/bind-users



--
I don't think the execution is relevant when it was obviously a bad idea in the first place.
This is like putting rabid weasels in your pants, and later expressing regret at having chosen those particular rabid weasels and that pair of pants.
   ---maf
_______________________________________________
Please visit https://lists.isc.org/mailman/listinfo/bind-users to unsubscribe from this list

bind-users mailing list
bind-users at lists.isc.org
https://lists.isc.org/mailman/listinfo/bind-users


More information about the bind-users mailing list