PHP/MySQL with Shared Hosting Limits?


#1

Hello. I recently have had clients wonder how much a PHP/MySQL site can handle in terms of hits/traffic/transfer and when it would be best to move that site to a co-lo or it’s own server?

Any references on that? I couldn’t seem to find any examples of blah.com (Fortune 500 Company) runs it’s site on PHP with shared hosting and it does fine. I understand the GB transfer limits, but I’m more looking for technology limitations with PHP and shared hosting.

Links to articles or tests would be very welcome. (:

thank you.


#2

[quote]Any references on that? I couldn’t seem to find any examples of
blah.com (Fortune 500 Company) runs it’s site on PHP with shared
hosting and it does fine.

[/quote]

Generally speaking, you’re probably not going to find any Fortune 500 companies that use shared hosting. If you’ve got that much money on-hand, you’re going to go with dedicated hardware - and probably a lot of it. That goes even if you don’t really need dedicated hardware, because big companies don’t like to take chances. For them, cost isn’t really much of an issue.

[quote]I understand the GB transfer limits, but I’m more looking for
technology limitations with PHP and shared hosting.

[/quote]

The main issue here is that you are sharing the same server with a whole lot of other people, meaning that anything they do has a potential to affect your site’s performance/stability/security.

Also, on a shared server you don’t get quite as much flexibility as you would on your own hardware. Need to edit the php.ini file? If it’s your own hardware, go ahead. The only person you could possibly hurt is yourself. On shared servers, though, we can’t allow it as you could cause problems for others.

You also don’t have as much flexibility in shared hosting with regard to installing 3rd party software (ie. mod_perl, Zend Optimizer, etc) - even if such installations would be technically unsupported on dedicated, at least you have an option.

Of course, since I’m Mr. Official DreamHost Guy™ here, and this post is looking suspiciously like I’m trying to sell you on a dedicated server, I’ll leave the rest to the other forum denizens. :>

  • Jeff @ DreamHost
  • DH Discussion Forum Admin

#3

jeff - thanks for the reply. i understand all the benefits of having my own server and being able to tweak it and secure it etc, but i want to know detailed stats on some stuff. things like …

  1. What are the limitations of a php / mysql site? as per hits/traffic/simultanious queries etc. what kind of load can it handle?
  2. What are the limitations of the shared dreamhost apache servers in regards to queries on the DB and PHP executing? Is it just when a site begins to drag and get slow? Certain hits per/hr/month etc?
  3. Is there a magic GB transfer number that you recommend a customer go to their own server rather than shared?

thanks. if you have any links to test reviews or anything that would be great. i was looking at the mysql and apache sites and couldn’t get any raw numbers of what their top out rate is. it’s like they all say the car can go fast and for a long while. i wanna know how fast in 6 seconds and how many miles on the highway on a full tank? know what i mean?

thank you ~ brent


#4

That actually consists of a large number of variables.
Its a combination of product achitecture, hardware/software specs, used platform, product configuration, objects handled by the product, used methods and so on…
“Most” of the time, the limiting factor is bandwidth related, and that can be anything from system bus, memory, hard drives, network, etc…
Its however not uncommon to reach a products hard limit when pushed far enough, used version (age) of the product and the way methods are being used.
Bad or inefficient coding will generally bring things down much faster, on either program or user space.
Most boundaries set out there are mere specs of used compilers, mere theoretical of course unless using the same framework on which it was developed/tested (HCL), and even then, a minor revision of things will probably deliver different results regarding speed and/or bandwidth consumption.

I would guess as long as it isn’t bothering the box where your DB is running from and aren’t eating away memory due to the amount of concurrent sessions, you should be safe, checkout this link here

(Assuming this also reflects on the PHP/mysql question)
Nope, its what you actually do with the DB, for example, if you’re serving images from a DB, it would require very little framework nor queries but lots of bandwidth in terms of network.
If on the other hand you’re performing a relational approach and do lots of subqueries, it would require far more computational power and disk access than just delivering contents from a table/record.
So it all depends on intended use before you can make such assessment.