Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

So I have 3 components all connecting to same db. Should I use:

comp1.domain.io  
comp1db.domain.io

comp2.domain.io  
comp2db.domain.io

comp3.domain.io  
comp3db.domain.io

Or:

comp1.domain.io  
comp2.domain.io  
comp3.domain.io  
db.domain.io

EDIT: I am wondering if the ease of API accessible Route 53 hostnames makes it more beneficial to create hostnames for the db server per application. This means if I need to transfer the DB of a particular application off to a different server, I just have to modify the hostname.

Traditionally it's usually db.domain.io, but that's because DNS entries is just not easily accessible and editable.

share|improve this question

closed as primarily opinion-based by EEAA, mdpc, Jacob, MichelZ, RolandoMySQLDBA Apr 28 at 12:30

Many good questions generate some degree of opinion based on expert experience, but answers to this question will tend to be almost entirely based on opinions, rather than facts, references, or specific expertise.If this question can be reworded to fit the rules in the help center, please edit the question.

1 Answer 1

up vote 1 down vote accepted

Your question has very little to do with Amazon Web Services but is connected to an overall server infrastructure layout. With that in mind I would recommend you structure your servers like this:

comp1.domain.io  
comp2.domain.io  
comp3.domain.io  
db.domain.io

While you say:

So I have 3 components all connecting to same db.

It’s not clear if you mean DB host or database itself. If for some reason each of the hosts needed their own DB, you could just come up with a database naming scheme such as:

comp1_db
comp2_db
comp3_db

And all of those DBs could be hosted at db.domain.io.

EDIT: This is in response to the original poster’s edit. If you have to transfer the DB, the process is never seamless & will take effort. A hostname change for something like this is fairly radical & is out of your control. Amazon Route 53 is one thing, but DNS behavior outside of the Amazon hosting ecosystem is another. It’s better for you in the long run to just use a common hostname but different DBs & perhaps related credentials.

share|improve this answer
    
Apology, please see edit. –  Sleeper Smith Apr 28 at 1:54
    
@SleeperSmith I saw you edit & I think you are overthinking the issue. See my edit in response. –  JakeGould Apr 28 at 2:04
    
Thanks for the input. They are indeed in different DBs –  Sleeper Smith Apr 28 at 3:36

Not the answer you're looking for? Browse other questions tagged or ask your own question.