i run my app on a l开发者_C百科inux os server with two dual core processors.
The thing is that on 'top' linux command, the second processor isn't loaded more than 10%, while the first one stays at 100% for 3-4 seconds on some scripts.
How can i use the power of those two CPU's of my server?
The only way to use multiple cores is to run multiple threads or processes.
For web applications there is usually one PHP process per running script, so this is already the case: Multiple requests will use multiple cores automatically.
You can't use multiple cores for the same request though, but usually this doesn't matter for a web app.
精彩评论