how to obtain its ip address ?

Michele Simionato michele.simionato at gmail.com
Thu Jun 24 00:27:32 EDT 2004


marco <manatlan at online.fr> wrote in message news:<40d9c75d$0$26573$626a14ce at news.free.fr>...
> I'd search a lot ... but i had not found
> how can i obtain my ip address (when i'm connected to the www) ?!
> 
> thanks a lot for any tips
> marco

In may case on linux this worked:

$ wget  -q "http://ipid.shat.net/iponly" -O - |sed -n 3p 

This gives your address as seen from outside, which is probably
what you want, whereas other solutions I tried were giving me
my local address on the LAN.

                       Michele Simionato



More information about the Python-list mailing list