How to tell IP address of remote machine?

Tom H tomh0665 at gmail.com
Sun Oct 25 18:26:40 UTC 2009


> ifconfig only seems to give the local 192.168.*.* address.
> Is there some way of getting it to tell the true IP address?

> (The remote machine is attached to an ADSL modem.
> I can get the IP address by accessing the modem,
> but I am not sure how I could automate this.
> I guess I could use lynx, and try to abstract the address ...)

What you seem to want is the ADSL modem's IP address.

Emailing yourself the (truncated to the first lines) output of a
"traceroute -n google.com" on your box should be enough to give you
the modem's external IP address. It will be the first external address
(and the first address if you do not have a router between it and your
box).




More information about the fedora-list mailing list