ab -n 1000 -c 20 means that you have 20 concurrent users making 1000 requests. The important part here is the concurrent bit.
There's a wide variety of things you can do to optimise your controller, which are way beyond the scope of a single post, especially since you don't really say anything about what your controller is doing. Turning on caching might help. The key to this is most likely memory based. Is your 70% usage just cpu, or is there wait time? Is memory swapping? You can do all sorts of things to cap rates, reduce linux's aggressive swapiness, or improve the use of disk. If memory's not the problem, maybe you could move cake's cache into ram. Cake can be very memory greedy if you use reconnect on datasources, or load a lot of models, or have a lot of relations. Lookup the expects() function on the bakery or look at bind(), unbind() if you want to deal with that the hard way. Other than that, it's probably a close investigation of you controller code and some optimisation there. Note also that ab will not provide a good test, since it does not download embedded resources (images / scripts / css etc) since it does not have any html parsing. You might do well to look at something like jakarta Jmeter, which is very good, if a little daunting for the beginner, or some of the dodgy cheap windows stuff like Website Optimizer (I think). Of course it may be that you just need a better server (the spec you stated is not exactly top of the range), or a separate database server / server cluster. You'd probably benefit hugely from a reverse proxy accelerator on a Cake site as well to take away all the js, css and image routes / rewrites / requests. Just some ideas. Hope they help. It's all a bit open-ended but I may be able to help more with a better description of the controller. Simon --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~----------~----~----~----~------~----~------~--~---
