I have been exploring moving some of my high traffic sites to the HPCloud over the past few days. While I have a general grasp of the idea behind a VM in the cloud there are things that are not quite clear to me. Here for instance is one thing I find myself wondering about:

If I host a site on a server in the cloud do I have an automatic guarantee that attempts to access that site will be served up from an instance of the VM in the geographic vicinity - with one being spun up if none is deemed to be "nearby"?

If the answer is "yes" then the next question that follows is - will the cloud infrastructure also deal with the process of running PHP scripts on each VM instance? And now about databases - will it be up to me to ensure that I connect to a fixed instance of the database server (mySQL in my case) or is it better to rely on one of the "cloud database" offerings that appear to make this process transparent.

I suspect that my questions are perhaps a bit naive - I don't know much about hosting in the cloud.

1 Answer 1


Yes, those systems work distributing loads and pages served, each one on different way.

Serving pages is usually done by selecting the nearest server, all of them share the same technologies, like PHP, MySQL, perl, etc.

About how the database works, there is basically one way, which is replicating the database server across the different locations of the cloud/servers. Of course those systems also have load balancing mechanisms to avoid overload, mitigate attacks, and improve service.

About how should you handle specifics about connecting to the database, the normal offer is that everything is on the same hosting side, not requiring you to connect to any other place. Of course that depends on what kind of plan you sing for, if the plan includes PHP and MySQL, then that is all organized and used by the different servers of the cloud service. If you subscribe to a plan that gives you space, but nothing else, then you only have storage, no PHP, no MySQL or anything else.

Yo have to read carefully what is the offer, what are the features of the plan, their coverage, etc.

  • You are indicating that basically the cloud infrastructure takes care of replicating the DB across each VM instance and I can use it as on a old-style physical server and trust the infrastructure to ensure that the DB is in sync across all VMs?
    – DroidOS
    Commented Feb 19, 2014 at 13:11
  • yes and no, it depends on the plan and the specific characteristics, for instance, there are systems where your database is in your VM, only, but they have proxies and caches working intensively on different "entrances" to the system and there all thee requests are cached and stored, so recurrent requests would look like served from different servers close to the user. Others give you access to a "central" DB, which is automatically replicated, so your account on that cloud access that remote/shared DB, but for you it looks like yours only ...
    – PatomaS
    Commented Feb 19, 2014 at 14:18
  • you have to ask on the site that you are interested on having the account for their features and how they work.
    – PatomaS
    Commented Feb 19, 2014 at 14:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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