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.

Possible Duplicate:
How do you do Load Testing and Capacity Planning for Web Sites

I am developing an PHP MYSQL application running on a Linux server I was wondering whether there is any way to test how many simultaneous users an application can handle?

Thanks

share|improve this question

marked as duplicate by Chris S Jul 31 '12 at 14:44

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

    
Thanks for your answers, they've really helped. –  Stanley Ngumo Oct 21 '09 at 9:26
add comment

3 Answers

up vote 1 down vote accepted

You actually need to test two things:

  • breaking point
  • scalablity

For finding the breaking point you can use apache benchmark (ab) for very raw stress testing or Selenium for more complex things. Regarding scaling you have to redo the previous tests with the application running on more powerfull hardware (scale up). Then with your app running from multiple webservers (scale out). Similar for the database backend but that's a littly trickier. When doing this type of tests it would help to have your machines monitored with tools like collectd/munin/zenoss and slow query log enabled in mysql so you can easily pinpoint any bottlenecks. For scale-out testing you can use Amazon's EC2 - 240$ , 100 servers for one hour if I remember correctly. The general idea when trying to profile a (web) application is to have a clear scaling path - i.e. where exactly you need more capacity, how you can provision it to the production environment and when you should do it.

share|improve this answer
add comment

I would use PHP (since you already know it) and write a script to query your application from a remote machine. It shouldn't be too hard to write the script to log in and navigate around, especially since you wrote the target application.

Write your script to test latency and other variables, and make sure to watch the resource utilization on the application server.

share|improve this answer
add comment

There are several tools to test your application under load. The one I've heard most about is JMeter. I believe you can also use part of the Selenium infrastructure to generate load testing.

share|improve this answer
add comment

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