In article <slrnae4v2f.6pk.mike / ratdog.stok.co.uk>, Mike Stok wrote:
> In article <pan.2002.05.14.14.36.26.727673.6068 / hotmail.com>, Seth Harper wrote:
>> I'm attempting to write a small script that retrieves a servers 
>> external IP adress, but I keep comming up with it's subnet IP, any 
>> suggestion on how to grab the external IP? Thank you much :)
>> 
>> Here's the Code for returning the the IP from the hostname:
>> 
>> host = Socket.gethostname
>> IP = IPSocket.getaddress(host)
> 
> Do you know the name of the external interface?  It may be different from
> what's returned by hostname.

Ignore me, plugging the right hostname into IPSocket.getaddress(host) works
and does all that conversion behind the scenes :-(

Mike

-- 
mike / stok.co.uk                    |           The "`Stok' disclaimers" apply.
http://www.stok.co.uk/~mike/       | GPG PGP Key      1024D/059913DA 
mike / exegenix.com                  | Fingerprint      0570 71CD 6790 7C28 3D60
http://www.exegenix.com/           |                  75D2 9EC4 C1C0 0599 13DA