ringerce Posted November 24, 2013 Share Posted November 24, 2013 (edited) Using Prestashop 1.5.4.1 and I recently moved to a dedicated server from a shared hosting account and yesterday we had about 100 active visitors on the website and it caused the server CPU to almost max out. Here are the servers specs: Intel Xeon Dual Core, 2.3GHz (4 threads) 100 Mbps Uplink 4 GB High Performance RAM 500 GB RAID-1 Drives 10 TB Bandwidth Rather than the server crashing we were getting errors about mysql exceeding the max number of connections allowed. My hosting company said if I were to raise the number of max connections the server would eventually just crash so we had to choice but to wait out the traffic burst. WHM process manager showed php and mysql to be bottlenecking the server: PHP: CPU Usage: 53.0% Memory: 1.2% Process: "/usr/bin/php /home/user/public_html/index.php" MYSQL: CPU Usage: 43.4% Memory: 8.0% Process: "/usr/sbin/mysqld --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib64/mysql/plugin --user=mysql --log-error=/var/lib/mysql/my.domain.com.err --open-files-limit=3072 --pid-file=/var/lib/mysql/my.domain.com.pid" My performance configuration for prestashop is as follows: Smarty: Template cache: Never recompile template files Cache: Enabled CCC (Combine, Compress and Cache) Use CCC for CSS: Enabled Smart cache for JavaScript: Enabled Keep inline JavaScript in HTML as original: : Enabled Apache optimization: Enabled Caching Use cache: Enabled Caching System: File System (I've tried using MemCached but it doesn't seem to work in Prestashop 1.5.4.1. Resulted in slower performance.) Any help troubleshooting this issue would be greatly appreciated. Edited November 24, 2013 by ringerce (see edit history) Link to comment Share on other sites More sharing options...
Dh42 Posted November 24, 2013 Share Posted November 24, 2013 How many products do you have in your shop? How many categories? How many attributes do your products have on average? How many items do you have on sale in your shop? On a server that size your open files limit for mysql is also set too low. Do you have a link to the shop too? What php interpreter are you using? Link to comment Share on other sites More sharing options...
ringerce Posted November 26, 2013 Author Share Posted November 26, 2013 Hello, Thank you taking the time to evaluate my situation. To answer your questions: How many products do you have in your shop? 407 active products. How many categories? 15 with 33 Manufacturers. How many attributes do your products have on average? 5-10 combinations. We have a few products that contain 25-35 combinations. I'm guessing we have around 6000-7000 unique products. How many items do you have on sale in your shop? I would say 70% of our store is on sale currently. On a server that size your open files limit for mysql is also set too low. Can you elaborate more on this? Do you have a link to the shop too? Sorry, I'm not allowed to post the shops link on forums unfortunately. What php interpreter are you using? PHPStorm. Please let me know if there is any more information you need and thank you for your help. Link to comment Share on other sites More sharing options...
Dh42 Posted November 26, 2013 Share Posted November 26, 2013 Php storm is an editor, the most common interpreters are dso, suPHP, Fcgi, and mod_php. You should create a php info and see which one you are using. As for the products on sale, if you are running the special block disable it and see if you can tell a difference. Link to comment Share on other sites More sharing options...
ringerce Posted November 27, 2013 Author Share Posted November 27, 2013 Oh sorry about that. My config is: Default PHP Version (.php files) 5PHP 5 Handler suphp Apache suEXEC onApache Ruid2 off No I'm not running the specials block module. Would it help to see the result of the profiler from prestashop? Link to comment Share on other sites More sharing options...
Dh42 Posted November 27, 2013 Share Posted November 27, 2013 The would help if you did. It is hard to tell what is wrong with a site having those kind of problems without having access to it. Link to comment Share on other sites More sharing options...
mark-b Posted November 28, 2013 Share Posted November 28, 2013 I have the same problem, I think my problem has to do with my theme... what is not made correctly I believe... I'm investigating it now.. Link to comment Share on other sites More sharing options...
ringerce Posted December 2, 2013 Author Share Posted December 2, 2013 On 11/27/2013 at 11:38 PM, Dh42 said: The would help if you did. It is hard to tell what is wrong with a site having those kind of problems without having access to it. I'll be getting you the result of the profiler later today. Thank you for your help. Link to comment Share on other sites More sharing options...
Recommended Posts