Take the 2-minute tour ×
Webmasters Stack Exchange is a question and answer site for pro webmasters. It's 100% free, no registration required.

I’m working on a community platform writen in PHP, MySQL.

I have some questions about the server usage maybe someone can help me out.

The community is based on JQuery with many ajax requests to update content. It makes 5 - 10 AJAX(Json, GET, POST) requests every 5 seconds, the requests fetch user data like user notifications and messages by doing mySQL queries. I wonder how a server will handle this when there are for more than 5000 users online. Then it will be 50.000 requests every 5 seconds, what kind of server you need to handle this?

Or maybe even more, when there are 15.000 users online, 150.000 requests every 5 seconds. My webserver have the following specs.

Xeon Quad 2048MB 5000GB traffic

Will it be good enough, and for how many users?

Anyone can help me out or know where to find such information, like make a calculation?

share|improve this question

1 Answer 1

How many users do you have online now?

You can test this yourself and get an idea of what you will need by using apache bench. You are talking about some very serious traffic, though. 30k requests a second is the limit for nginx serving static content, let alone php/mysql type content.

You can't just calculate this, you need to test it, as there are a number of factors involved here. - Are you using Apache, Nginx? - How expensive are these queries? - How many records are you querying? - Are you doing any kind of caching?

My guess is you are going to need much bigger hardware for MySQL, and PHP might not be the best choice for handling the AJAX requests.

share|improve this answer

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.