fully qualified hostname ?
claird at starbase.neosoft.com
Thu Aug 26 21:46:50 CEST 1999
In article <199908261822.AA01099 at ch1d2833nwk>,
Ted Horst <Ted.Horst at wdr.com> wrote:
>What is the best way to get the fully qualified hostname in python (ie
>A portable solution would be ideal, but I would settle for Unix only.
There's a lot of ambiguity in the question of which
you're not aware. A perfectly well-behaved network
host might have several fully-qualified hostnames,
or none. One can even make a case that a single
host is best known by different names on different
So: you're definitely entering the land of some-
what sloppy heuristics. The first thought that
occurs to me is a reverse DNS lookup; is that ade-
quate to your situation?
Note, also, that many Python instances run on host-
Cameron Laird http://starbase.neosoft.com/~claird/home.html
claird at NeoSoft.com +1 281 996 8546 FAX
More information about the Python-list