chipslay Posted October 6, 2014 Share Posted October 6, 2014 My prestashop is currently using up to 97% and up of memory. It used to be at 70% and then one day it started using more memory for no reason. Well I did not change a setting. I am on a VPS server. I need guidence to detecting the problem with a memory leak and fixing it. I thought I had it pegged as a layered navigation block module but I disabled it and now I am stumped. I am not good at server admin stuff so all the help would be appreciated. I am however very familiar with Prestashop. THANKS!!!! I am using version 1.6.0.9 ( I just updated to see if it would fix it ) I also tossed my theme and I am using the default bootstrap because my 1.6 theme would have problems I understand. Link to comment Share on other sites More sharing options...
Dh42 Posted October 7, 2014 Share Posted October 7, 2014 How much memory do you have allocated to PrestaShop? Link to comment Share on other sites More sharing options...
chipslay Posted October 7, 2014 Author Share Posted October 7, 2014 I have 2 Gigs. I am on a VPS server with Pacific Host. Link to comment Share on other sites More sharing options...
chipslay Posted October 8, 2014 Author Share Posted October 8, 2014 I was using 1.7 gigs on average before now its up to 1.87 plus. I have two gigs of Ram. I have shut down MUNIN. Also as always when I look into the resources its alway PHP scripts causing the spikes. So I don't know if the spikes are normal or not. There is not much information on this at all anywhere. So CPU is fine and I have 2 gigs allocated. Also, to cut back on RAM I drop the PHP INI to max 80 and not the 120 it had. I can drop it to 40 and the shop actually still performs well. I know that is not recommended but it works. Thanks for all your help!!!!!!!!! Link to comment Share on other sites More sharing options...
chipslay Posted October 8, 2014 Author Share Posted October 8, 2014 (edited) I just heard from my server people and they are pointing to php scripts as suspected. Here is the email they sent me .... We have investigated the issue and concluded that your server is out of memory , you have already used 1957/2048 of the memory ======================================root@server [~]# free -mtototal used free shared buffers cachedMem: 2048 1957 90 0 0 0Swap: 0 0 0Total: 2048 1957 90=====================================Also as per memory output we can determine the memory usage at this particular time root@server [~]# sar -rLinux 2.6.18-348.16.1.el5.028stab108.1 (??????????????????????) 10/08/201412:00:01 AM kbmemfree kbmemused %memused kbbuffers kbcached kbswpfree kbswpused %swpused kbswpcad12:10:01 AM 98248 1998904 95.32 0 0 0 0 0.00 012:20:01 AM 22684 2074468 98.92 0 0 0 0 0.00 012:30:01 AM 83640 2013512 96.01 0 0 0 0 0.00 012:40:02 AM 191068 1906084 90.89 0 0 0 0 0.00 012:50:01 AM 79652 2017500 96.20 0 0 0 0 0.00 001:00:01 AM 81640 2015512 96.11 0 0 0 0 0.00 001:10:01 AM 113776 1983376 94.57 0 0 0 0 0.00 001:20:01 AM 77720 2019432 96.29 0 0 0 0 0.00 001:30:02 AM 172968 1924184 91.75 0 0 0 0 0.00 001:40:01 AM 81516 2015636 96.11 0 0 0 0 0.00 0=====================================================================================Status:OnlineMemory Usage: 95%1.9 GB of 2 GB Used / 97.5 MB FreeDisk Usage:76%38 GB of 50 GB Used / 12 GB FreeBandwidth Usage:0%2.9 GB of 3.2 TB Used / 3.2 TB FreeNode: cannonballTraffic Graph Unavailable===========================================Also as we checked the Logs we got ============================================================grep -ir memory /var/log/messages Oct 5 05:27:37 server suhosin[26271]: ALERT - script tried to increase memory_limit to 268435456 bytes which is above the allowed value (attacker '108.178.60.2', file '/home/icanhelp/public_html/shop/classes/Module.php', line 2) Oct 5 05:28:56 server suhosin[26271]: ALERT - script tried to increase memory_limit to 268435456 bytes which is above the allowed value (attacker '108.178.60.2', file '/home/icanhelp/public_html/shop/classes/Module.php', line 2) Oct 5 05:42:37 server suhosin[29929]: ALERT - script tried to increase memory_limit to 268435456 bytes which is above the allowed value (attacker '108.178.60.2', file '/home/icanhelp/public_html/shop/classes/Module.php', line 2) Oct 5 06:43:19 server suhosin[10041]: ALERT - script tried to increase memory_limit to 268435456 bytes which is above the allowed value (attacker '91.240.109.71', file '/home/icanhelp/public_html/shop/classes/Module.php', line 2) Oct 5 06:43:30 server suhosin[10041]: ALERT - script tried to increase memory_limit to 268435456 bytes which is above the allowed value (attacker '91.240.109.102', file '/home/icanhelp/public_html/shop/classes/Module.php', line 2) Oct 5 07:48:21 server suhosin[24277]: ALERT - script tried to increase memory_limit to 268435456 bytes which is above the allowed value (attacker '157.55.39.113', file '/home/icanhelp/public_html/shop/classes/Module.php', line 2) Oct 5 11:55:08 server suhosin[9774]: ALERT - script tried to increase memory_limit to 268435456 bytes which is above the allowed value (attacker '98.251.166.154', file '/home/icanhelp/public_html/shop/classes/Module.php', line 2) Oct 5 17:08:35 server suhosin[10027]: ALERT - script tried to increase memory_limit to 268435456 bytes which is above the allowed value (attacker '66.249.64.159', file '/home/icanhelp/public_html/shop/classes/Module.php', line 2) Oct 5 18:18:47 server suhosin[25888]: ALERT - script tried to increase memory_limit to 268435456 bytes which is above the allowed value (attacker '54.80.8.135', file '/home/icanhelp/public_html/shop/classes/Module.php', line 2) Oct 5 18:18:47 server suhosin[25888]: ALERT - script tried to increase memory_limit to 268435456 bytes which is above the allowed value (attacker '54.80.8.135', file '/home/icanhelp/public_html/shop/classes/Module.php', line 2) Oct 5 20:17:24 server suhosin[18009]: ALERT - script tried to increase memory_limit to 268435456 bytes which is above the allowed value (attacker '208.115.111.68', file '/home/icanhelp/public_html/shop/classes/Module.php', line 2) Oct 6 04:32:54 server suhosin[27996]: ALERT - script tried to increase memory_limit to 268435456 bytes which is above the allowed value (attacker '178.137.87.181', file '/home/icanhelp/public_html/shop/classes/Module.php', line 2) Oct 6 06:58:06 server suhosin[26188]: ALERT - script tried to increase memory_limit to 268435456 bytes which is above the allowed value (attacker '91.240.109.99', file '/home/icanhelp/public_html/shop/classes/Module.php', line 2) Oct 6 06:58:17 server suhosin[26188]: ALERT - script tried to increase memory_limit to 268435456 bytes which is above the allowed value (attacker '91.240.109.110', file '/home/icanhelp/public_html/shop/classes/Module.php', line 2) Oct 6 08:53:06 server suhosin[17766]: ALERT - script tried to increase memory_limit to 268435456 bytes which is above the allowed value (attacker '157.55.39.113', file '/home/icanhelp/public_html/shop/classes/Module.php', line 2) =========================================================================Its suggested that you need to customize the script as it is causing the memory issue , also its suggested you upgrade your plan to pinnacle inorder to avoid such problems in the future Please update us if you feel any issues. Please feel free to contact us for further help. We are committed to making your hosting experiences pleasant and fulfilling. Edited October 8, 2014 by chipslay (see edit history) Link to comment Share on other sites More sharing options...
Dh42 Posted October 8, 2014 Share Posted October 8, 2014 You have a module that is running out of control basically. You or someone else needs to disable modules to figure out which one it is. Link to comment Share on other sites More sharing options...
chipslay Posted October 8, 2014 Author Share Posted October 8, 2014 Is there somewhere you can look to find out which one it is? Link to comment Share on other sites More sharing options...
Dh42 Posted October 8, 2014 Share Posted October 8, 2014 I would look what is hooked into the left column. Link to comment Share on other sites More sharing options...
chipslay Posted October 8, 2014 Author Share Posted October 8, 2014 The only left module I am using is Layered Navigation. You still did not tell me how much ram Prestashop should have. Link to comment Share on other sites More sharing options...
El Patron Posted October 8, 2014 Share Posted October 8, 2014 turn on prestashop profiling config/defines.inc.php set to true define('_PS_DEBUG_PROFILING_', false); then run through pages, collect information...set back to false as everyone sees profiling data. Link to comment Share on other sites More sharing options...
Dh42 Posted October 8, 2014 Share Posted October 8, 2014 Sorry about the response before, that was to another thread. My off the top of the head guess is that you have all of your products associated with the home category and your home featured is eating up the resources. Link to comment Share on other sites More sharing options...
chipslay Posted October 9, 2014 Author Share Posted October 9, 2014 Not all but allot. I will try that. Thanks for the Ideas. I will report what fixes it when it is SO HAPPILY FIXED! Right now I still don't know how much RAM prestashop is supposed to have. I have just paid $100 to increase it to 2.8 gigs and its peaking at 2 ....... Then I will find out what module is responsible but as it looks I think Prestashop needs over 2 dedicated gigs to run ........... Am I Wrong??????? Link to comment Share on other sites More sharing options...
chipslay Posted October 9, 2014 Author Share Posted October 9, 2014 Everybody is scared to put a numbers on this LOL. IS is bad for business or something if it uses too much RAM? Link to comment Share on other sites More sharing options...
Dh42 Posted October 9, 2014 Share Posted October 9, 2014 I can debug it an let you know what exactly is wrong for $100usd if you would like. It is a service we offer fairly regularly. It is using too much resources more than likely, but there are a lot of factors that come into play as well. As far as numbers what kind are you meaning? Link to comment Share on other sites More sharing options...
El Patron Posted October 9, 2014 Share Posted October 9, 2014 turn on prestashop profiling config/defines.inc.php set to true define('_PS_DEBUG_PROFILING_', false); then run through pages, collect information...set back to false as everyone sees profiling data. did you follow this, maybe you missed it. Link to comment Share on other sites More sharing options...
chipslay Posted October 10, 2014 Author Share Posted October 10, 2014 Ok so I am going to say ..... IF YOU HAVE A VPS SERVER YOU NEED AT LEAST 1.5 GIGS OF RAM TO RUN PRESTASHOP. SOLVED! Link to comment Share on other sites More sharing options...
Dh42 Posted October 10, 2014 Share Posted October 10, 2014 I don't think that is true, it all depends on the shops setup. One size fits all does not work with servers or with shops. Your shop might require that, but I am guessing if it does something is configured wrong. Link to comment Share on other sites More sharing options...
El Patron Posted October 10, 2014 Share Posted October 10, 2014 you will never know because you do not follow advice... 1 Link to comment Share on other sites More sharing options...
nanogioia Posted April 22, 2015 Share Posted April 22, 2015 I am having extremely slow prestashop 1.5.6.2. This was running okey in a vps server with 2gb of ram, now i went to a cheaper server with 2048MB and its working really slow, might this be the real problem, because its strange that it needs so much RAM. Prestashop is said to need just 64MB to run. Thank you! Link to comment Share on other sites More sharing options...
Recommended Posts