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

I'm currently running a VPS that uses ~1.5GB of ram. I'm thinking of switch to Amazon EC2, because access to our host is pretty slow, lots of downtime, etc.

An EC2 small instance has 1.7GB, so I assume if I want to migrate I'm going to need more than one instance. The idea would be to run Apache on one instance and MySQL on another, then figure out where to run the rest of my processes (Mono, Red5, etc.) based on RAM usage on either instance.

I'm not really a server professional, so I don't know if this makes any sense, or if there is something I am missing. Will there be a big performance hit if Apache (Wordpress, etc.) has to access databases on another EC2 instance? Anything else that might make this a bad idea?

share|improve this question

1 Answer 1

up vote 3 down vote accepted

In short: Yes, this can make a lot of sense.

It can make a lot of sense to have specific servers for different services. This is more common in the case of having separate hardware for different servers, but can make sense in the case of VPS's too; eg. different file systems provide different benefits to different applications, different mount options can help/hinder different access patterns, and other software related tweaks. You also get hard barriers between services so that eg. Apache/PHP doesn't eat up all the CPU and kill other services that may be using MySQL.

To the point of MySQL specifically, Amazon offers RDS instances which are dedicated MySQL instances. This gives a remote instance that is preconfigured and pretuned for running MySQL and makes for a very good way of doing exactly what you are looking at. The down side of RDS is that you won't be able to install other applications on the database server as I don't believe you get the same access as you do to a EC2 instance. This means you may need three instances, or a larger first instance, depending on exactly what else you are looking at running on it. Another service you may want to look into is Amazon's VPC.

share|improve this answer
    
Oh, wonderful... I didn't see RDS instances :) As it says, "an application running in Amazon EC2 will experience low-latency database access to an Amazon RDS DB Instance in the same region." Sounds like just what I need. With MySQL on its own, I think a small EC2 instance would be enough for everything else. Thanks for the help! –  yuttadhammo Nov 2 '11 at 8:08
    
I wonder if you can comment on the fact that RDS seems to be more expensive than an ordinary EC2 instance. Is it really worth all that preconfiguring and pretuning? Or is there something else that makes it better than a second EC2? –  yuttadhammo Nov 4 '11 at 5:17
1  
@Yuttadhammo: I've not used RDS myself, so I can't speak to it's effectiveness. We noticed it too late in our deployment to make it worth it. –  Matthew Scharley Nov 4 '11 at 5:23

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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