Live data from Hacker News

Hostnames

seriss.com

171–180 of 187 posts

Re: Hostnames

#171

python -c "import random; print random.choice(open('/usr/share/dict/words').read().split())" Nerd factor: really, really high. P.S. you're still allowed to exercise the power of veto. I've managed to convince others to let me use this technique to form a team name in a couple of Uni projects.

That is really neat. Never even through of that.

"protonymphal" -- I think I want to call my new band that.

Re: Hostnames

#172
post #53

Periodic table: hydrogen, helium, lithium, beryllium, boron, carbon... and shorthands... h.yourcompany.net, etc... :)

I've always struggled to remember the correct spellings of some elements' names, and this looks like a good reason to do it all right!

Re: Hostnames

#173

Earlier quoted context omitted.

Until you have 27 hostnames.

That's when we go Greek, say hello to α.

But you get a collision right on the first element. Alpha leads off both the phonetic alphabet and Greek alphabet. Delta also collides.

Re: Hostnames

#174

After working in a few pretty large environments I have some pretty strong opinions about hostnames. I've seen everything from cute theme based names to function/role based names to meaningless uuid based names. Usually you see the theme based names in much smaller environments, though I've seen it up to hundreds of machines. One problem I have with this approach is that people begin to personify machines, excusing t…

The company I work for has about 20 sites with over 200 servers per site. We have cobbler boxes in each site (and more recently, puppetmasters). While some of our utility servers run as VMs under either VMWare or KVM, for the bulk of them we want every last scrap of performance out of the server that we can, so we primarily provision on physical machines and treat those physical machines as just containers.

Our naming scheme for the servers is similar to how you describe dropbox - there is a generic prefix and then a rack+uposition number (ie: gen0112). This has worked out pretty well. When we build a site or replace a server, we record the mac address. Then we can assign role-based child hostnames to the physical server name, update the cobbler config, and everything gets built accordingly.

Of course, there is a nice host database to track all these mappings as well as scripts to generate and push those cobbler configurations.

Re: Hostnames

#175
I work for a large company that has multiple locations and sub business and many buildings have multiple data centres. By looking at the name, we can tell if its a prod / dev or a test server, location of the server ( city/building code and DC number), generic function ( DB -database could be any type of db , FS- file server, etc ) and unique number. Pretty good to pinpoint the location of the server globally but useless when you need to find out the exact function. While our inventory system is kind of OK, keeping it updated is a pain.

Re: Hostnames

#177

After working in a few pretty large environments I have some pretty strong opinions about hostnames. I've seen everything from cute theme based names to function/role based names to meaningless uuid based names. Usually you see the theme based names in much smaller environments, though I've seen it up to hundreds of machines. One problem I have with this approach is that people begin to personify machines, excusing t…

I've been part of some of large scale setups where usually location (even numbers = DC A, odd nubers = DC B), operating system (linux/aix/win etc.) and machine type (physical vs. virtual) are encoded in the hostname.

It can only get error prone if you have two hosts with similar names in the same project (made up example: lnx4739p34 vs. lnx4793p34) in the same project, i've seen hostnames getting reassigned because of regular mix ups.

If you happen to do ssh logins and manual troubleshooting, to make sure you're not messing with the wrong machine it's great to have puppet maintain CMDB data like service level, machine purpose, owner and open tickets etc. in a nicely formatted /etc/motd file, along with a autmatic "who" output in .bashrc to see who else is logged in.

Another question regarding hostnames is the use of (sub)domains. I find it highly annoying to deal with hosts like "mysql04.customer.vlan33.berlin2.intranet.my-company.com" instead of "lnx4739p34.myco.net", regardless of the global location.

Re: Hostnames

#178

My ISP in the 90s had fruits for hostnames. The main Cisco router was called 'passion'. Shortly after setting it up, I pinged it from a Solaris box. The response was 'passion is alive'. I tell this story every time there is a 'what do you call your hosts?' discussion!

We had a host called 'elvis' for the very same Solaris ping response reason.

Re: Hostnames

#179
post #53

Periodic table: hydrogen, helium, lithium, beryllium, boron, carbon... and shorthands... h.yourcompany.net, etc... :)

This is my favorite one. For extra awesome, you can use the atomic mass of each element as the last octet of the device's IP address.

Nice - but don't you mean Atomic Number, not Atomic Mass? The atomic numbers (i.e. the count of protons in the nucleus) are the nice non-overlapping integers 1-118, whereas the masses are all over the shop, and has overlap with isotopes of other elements.

Re: Hostnames

#180
post #169
post #97

First rule of running a farm: don't name your animals. You'll get too emotionally attached when it comes time to put them down. Yes it's funny and cool et cetera. But, and I say this with love and twenty years' experience, for fucksake: take the time to plan a sensible ontology and stick with it. Hostnames should describe the purpose, capabilities, and disposition of your assets. Nothing more and nothing less.

This approach "Hostnames should describe the purpose, capabilities, and disposition of your assets" requires you to rename your servers when you repurpose them. And that's an equally bad idea.

Nah, renaming during a reprovision is fine. You gotta stuff that information somewhere, and it might as well be in the name of the thing. Also remember that a machine / IP address can have as many alternate names as you want in the DNS system.
Post reply on HN