Re: Get the external IP address from a Linux box
likcoras writes:
> >>
> >> I am looking for a native package on Debian, that can give me the
> >> external IP address of the machine.
> >>
> >
> > Hi Andre.
> >
> > Type "ifconfig" without the quotes. The record you are looking for is
> > inet addr: for IPV4. Its about the second line from the top.
> >
>
> ifconfig would only work if you are directly assigned the public,
> external IP. If you are behind eg. a router that does NAT, you would
> only see the private IP internal to the local network.
>
Then:
dig TXT +short o-o.myaddr.l.google.com @ns1.google.com
John
--
John Conover, conover@rahul.net, http://www.johncon.com/
Reply to: