Re: [PATCH] Add compile domain (was: Re: [PATCH] Well, Linus seems to like Lordi...)

From: Joshua Hudson
Date: Mon May 29 2006 - 16:47:33 EST


Yeah, hostname --fqdn is so broken:

joshua@numenor:~$ hostname
numenor
joshua@numenor:~$ hostname --fqdn
numenor
joshua@numenor:~$

My normal take is not to use the FQDN as the hostname because it
becomes too long.
If I ever need to know my outside-facing IP address, I connect a UDP
socket to 1.2.3.4
and to a getsockname(). To get outside-hostname, I do a reverse-lookup on that.
Since 1.0.0.0/8 will never be allocated, this is gauranteed to work
when there is a way out.
If there's no way out, I'll find that out too.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/