someone should tell google to avoid certain subdomain names
It all began this morning, when someone pointed me to the fact that the domain gemablog-.blogspot.com wasn't resolving correctly.
What? of course it is not resolving - was my first thought - did you see the - at the end of the subdomain name?
As you can read in RFC-1034:
The labels must follow the rules for ARPANET host names. They must start with a letter, end with a letter or digit, and have as interior characters only letters, digits, and hyphen. There are also some restrictions on the length. Labels must be 63 characters or less.
I know there are some other RFCs that added some modifications to that rule later on, but I didn't find any that allow us to use - at the end of a subdomain or domain name (please do correct me if I'm wrong).
The funny part of the story is that, depending on your operating system and the tool you are using, that domain will resolve, or not.
For example:
dig works in FreeBSD 7 and 8, OpenBSD 4.2 and 4.6, Ubuntu Karmic, Linux Mint Helena, Debian Lenny and MacOSX Leopard
ping works in OpenBSD 4.2 and 4.6 and in MacOSX Leopard, but it doesn't on the other ones, resulting in different errors:
In Linux I got:
ping: unknown host gemablog-.blogspot.com
While in FreeBSD I got:
ping: cannot resolve gemablog-.blogspot.com: Unknown server error
The same happens to some other tools (like lynx or links) or even if you try to open connections to that hostname using a programming language.
Adding a line in /etc/hosts for the domain (pointing to the appropiate ip address) solves the problem.
Anyone that could add a reasonable explanation on this?
OH! and it is not only google who is doing that, seems there are some other domains that allow users to use such subdomain naming scheme (while others don't, like dyndns.org).