I am running a ecommerce website developed in magento. I have 512mb RAM and 2.6 core2duo on the server. When I send 50 requests at a time on my website it does not respond except for a few requests. I have installed varnish too. I want to know the optimal settings that i want to do for my website. I have seen that PHP-FPM is taking too much memory and cpu usage.
相关问题
- Views base64 encoded blob in HTML with PHP
- Laravel Option Select - Default Issue
- PHP Recursively File Folder Scan Sorted by Modific
- Can php detect if javascript is on or not?
- Using similar_text and strpos together
You should increase memory more than 512m, because nginx + php-fpm and varnish run use more than memory of system. i conduct overflow and php process can not enough ram to excute
Background
We use nginx and php5-fpm on ubuntu 12 on our production machine (VCenter Virtual Machine, 4 cores, 8 GB ram). Our magento installation is heavily themed and extended. Just for kicks the other day I installed everything from scratch on a VMWare box with a default installation of Magento 1.12 EE (I needed to call them out on a bug). I just say this so you know that we've got nginx and php5-fpm in a production environment.
What you are asking is something I think everyone struggles with using nginx and php fpm... Squeezing more performance from it. I mean, we could just use apache and php if we weren't trying to get the site performance increase right? There are a lot answers, opinions, and case base solutions, but I'll point you to the guide I used to configure my system...
http://www.if-not-true-then-false.com/2011/nginx-and-php-fpm-configuration-and-optimizing-tips-and-tricks/
Taken from the blog comments:
It may not answer every question you have, but there are a lot of good things to make sure you do... Like setting worker_processes = how many cores you have etc.
Personally one thing I still have trouble with is if server load gets really high (more than 5 - 10 hits per seconds) the processors are hammered. I haven't fully nailed down the problem, but adding a core and bumping the ram made a significant dent. I may increase the ram more, but at this time our user base is not seeing any site performance problems.
(Found from another site blog post:)