[Linux-disciples] Finding an external IP
Adam Rosi-Kessel
adam at rosi-kessel.org
Tue Nov 22 17:08:20 EST 2005
Why do you have to run dig from an external machine? Can't you just specify
an @external nameserver?
Stephen R Laniel wrote:
> I want to figure out what IP address the external world sees
> for a given hostname. I could ssh to a remote host and run
> ping -- something like
>
> ssh remote_host ping -c 1 hostname
>
> where 'hostname' is the one for which I want the IP. Then I
> could parse the output in various ways.
>
> The trouble is that a lot of the hostnames I'm interested in
> will give fallbacks. So for instance, I want to know what IP
> address the external world thinks that
> adam.americanprogress.org has. If I just ping it, I'll get
> back 216.234.246.150, when what I really want to know is
> that adam.americanprogress.org is not externally visible.
>
> As far as I can tell, the best way to discover that bit of
> information is to run dig from an external machine, look for
> the ANSWER section, and munge the results appropriately.
> Which is what this script does:
>
> http://laniels.org/scripts/remote_dns_query.pl.txt
>
> If anyone can think of a better way to do what I want, lemme
> know.
>
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Linux-disciples mailing list
> Linux-disciples at lists.bostoncoop.net
> http://lists.bostoncoop.net/mailman/listinfo/linux-disciples
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 250 bytes
Desc: OpenPGP digital signature
Url : http://lists.bostoncoop.net/pipermail/linux-disciples/attachments/20051122/5987e667/signature.pgp
More information about the Linux-disciples
mailing list