So you want to break the network layer? Question. Did you read what Jim Young linked to before making this post?
@magicalclick: I wasn't thinking of my use case in particular, it just mentioned it as an example. Also I don't mean to imply doing DHCP and DNS was a problem in an internal network.
Using my work as an example again, right now for us new VMs get assigned names automatically via DHCP, however they are not particularly memorable, so in most cases we all just use the IPv4 address (they are stable long enough to do our testing).
So it is clear the original idea won't work on the internet due to the routing issue. Fair enough. But lets take an example of a LAN...
So, here is how it goes typically in the current implementation:
- You power on a new VM.
- The new VM gets assigned a DNS name and IP address via DHCP, let's say the name is something like "testlab-3-dhcp-1234" or whatever.
- You now have to take note of either the DNS name or the IP address. Since the IPv4 address is shorter, we usually just use that directly as they are stable long enough.
- Whenever you need to access the VM from somewhere else (like say RDP into it), you need to use the name or IP address you noted from the previous step.
OK fine, not a big deal. What I'm suggesting would make the process a bit more user friendly and goes something like this:
- You power on a new VM.
- In its network settings, for each NIC you give a memorable name of your choosing, like say "bitflipper-superbugfix-test" (this name could default to the MAC address of the NIC to give it a unique default address on the LAN).
- Once you enter the name, it uses a SHA hash to create a unique local IPv6 address, and assigns it to the NIC as a static IPv6 address.
- You can now access the VM on the LAN using your chosen name as if it was a DNS name.
The main advantage would be that you can choose your own names and never have to see an actual IP address (so it doesn't matter that it is an IPv6 address underneath). Another advantage is that you don't need to involve DHCP/DNS servers.
This won't work with IPv4 since there will be too many collisions, but with IPv6 that should not be a problem. In the rare case that there is a collision, you will be notified to use a different name (whether due to an actual hash collision - highly unlikely, or due to using an existing name, it doesn't matter).
EDIT: When I say "You can now access the VM on the LAN using your chosen name as if it was a DNS name", I mean this is all built into the network stack, and the local IPv6 address will be re-created via the same hashing algorithm, and hence doesn't require a trip to the DNS server.