Jump to content

Loading time


marketyellow3

Recommended Posts

Hello,

 

The loading time of my website is very slow it can take up to 13 seconds before the page is loaded and i tried different things like better server and looked for fixes but i didn't find the solution. I already turned on all CCC and cache is turned on, also turned off force compile.

 

Does somebody also having this same problem and  fixed this? let me know thanks!!

 

Information:

 

My website: http://autoonderdelenexpres.nl

Prestashop version: 1.6.1.12

Theme: default-bootstrap

server specs:

- 4 Intel Nehalem-C

- 8GB RAM
- 5.6.31 PHP version
- 5.5.41 MYSQL version
Link to comment
Share on other sites

I can confirm the 13 to 15 seconds to load a page. If I look into the network analysis, I can see that only delivering the plain HTML takes appx. 13 seconds. The rest (like images, css, javascript) seems to perform more or less normally, even when these resources are not loaded very quickly.

 

I would do the following:

- Disable all (really all) non-default modules. Check times again. If better, figure out which module or modules lead to decrease in site performance.

- Check your prestashop performance settings. We don't know anything on them so far.

- Check your webservers error log. Some kind of errors may lead to a significant performance degradation.

Link to comment
Share on other sites

My performance settings:

 

Template compile: recompile template files never

Cache: yes

Kind of caching: File system

Empty cache: every time something is changed

 

CCC:

All yes

 

Codering:

 

Rijndael

 

website error log:

 

[Thu Sep 28 15:12:45.629860 2017] [proxy_fcgi:error] [pid 19642:tid 139648319719168] [client 80.112.24.23:54225] AH01071: Got error 'PHP message: PHP Notice: Undefined index: id_currency in /home/onderdelen/domains/autoonderdelenexpres.nl/public_html/tools/smarty/sysplugins/smarty_internal_templatebase.php(157) : eval()'d code on line 87\nPHP message: PHP Notice: Trying to get property of non-object in /home/onderdelen/domains/autoonderdelenexpres.nl/public_html/tools/smarty/sysplugins/smarty_internal_templatebase.php(157) : eval()'d code on line 87\n', referer: http://autoonderdelenexpres.nl/beheer/index.php?controller=AdminModules&token=61d1935eaa67e564c1a832a307fdc4ca
[Thu Sep 28 15:23:42.728266 2017] [proxy_fcgi:error] [pid 19483:tid 139648378533632] [client 80.112.24.23:54544] AH01071: Got error 'PHP message: PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 32 bytes) in /home/onderdelen/domains/autoonderdelenexpres.nl/public_html/tools/profiling/ObjectModel.php on line 41\n'
[Thu Sep 28 15:23:49.334857 2017] [proxy_fcgi:error] [pid 19642:tid 139648563107584] [client 80.112.24.23:61592] AH01071: Got error 'PHP message: PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 72 bytes) in /home/onderdelen/domains/autoonderdelenexpres.nl/public_html/tools/profiling/ObjectModel.php on line 41\n', referer: http://autoonderdelenexpres.nl/dakdragers/bmw
[Thu Sep 28 15:23:52.324506 2017] [proxy_fcgi:error] [pid 19642:tid 139648328111872] [client 80.112.24.23:54545] AH01071: Got error 'PHP message: PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 32 bytes) in /home/onderdelen/domains/autoonderdelenexpres.nl/public_html/tools/profiling/Db.php on line 113\n'
[Thu Sep 28 15:26:37.463885 2017] [proxy_fcgi:error] [pid 19483:tid 139648126752512] [client 80.112.24.23:54580] AH01071: Got error 'PHP message: PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 72 bytes) in /home/onderdelen/domains/autoonderdelenexpres.nl/public_html/tools/profiling/ObjectModel.php on line 41\n'
[Thu Sep 28 15:26:44.348608 2017] [proxy_fcgi:error] [pid 19642:tid 139648269362944] [client 80.112.24.23:54593] AH01071: Got error 'PHP message: PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 64 bytes) in /home/onderdelen/domains/autoonderdelenexpres.nl/public_html/tools/profiling/ObjectModel.php on line 41\n'

Link to comment
Share on other sites

You have several issues, the biggest of all is a leak of available memory for PHP.

 

[Thu Sep 28 15:23:52.324506 2017] [proxy_fcgi:error] [pid 19642:tid 139648328111872] [client 80.112.24.23:54545] AH01071: Got error 'PHP message: PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 32 bytes) in /home/onderdelen/domains/autoonderdelenexpres.nl/public_html/tools/profiling/Db.php on line 113\n'

 

You need to incerease you PHP memory. Usually this can be done by the hosting panel or php.ini settings. What surprises me: We can run PS 1.6.1.13 with 128 MB of memory. Maybe some non-default setup leads to higher memory demand on your installation. Try to increase to 256 MB.

Link to comment
Share on other sites

1. Disable all non-default modules. Check again.

2. Enable the slow query log for your database and check what it logs (you have to change to database session or configuration file) to enable that.

https://dev.mysql.com/doc/refman/5.7/en/slow-query-log.html

3. Rescan your error log for further errors.

Edited by Scully (see edit history)
Link to comment
Share on other sites

I recommend :

 

1 trace all SQL queries, try to find what is slow for you

2 check that your server has SSD drive, if do not have setup SSD

3 check Available memory at server

4 check that prestashop uses caching  (not in debug mode)

5 increase memory limits for PHP & MySQL

Link to comment
Share on other sites

Hi,

I see your store loading time 8.x seconds.

Store url analysis using gtmetrix helps to find issues related speed and where improvements require.

I see Yslow recommendation use of CDN for media files,add expires headers and use cookie free domain.

https://gtmetrix.com

PrestaShop Tutorials Videos [How to do Tasks]

https://www.prestashop.com/forums/topic/907438-prestashop-tutorials-videos-how-to-do-tasks/

Edited by Zohaib-fk
Post Updated (see edit history)
Link to comment
Share on other sites

Hi, to run and collect your PrestaShop run-time you can enable PrestaShop Profiler.

 

open file config/defines.inc.php  (on or around line 42) change

define('_PS_DEBUG_PROFILING_', false);

to 

define('_PS_DEBUG_PROFILING_', true);

disable debug profiling when completed testing!

 

now visit your slow pages and scroll to bottom of page there you will see the PrestaShop profiling information.

 

TIP: it's easy to determine if this is result of 3rd party module or override by disabling them and resting, see here

09.28.2017-16.54.png
https://www.screencast.com/t/80YoEjTgt

Edited by El Patron (see edit history)
  • Like 1
Link to comment
Share on other sites

About post #6 is turned off all non-default modules but the loading speed was still the same i also check this on a 2th server with a fresh installation there was is just really fast. For MYSQL i need the proper PHPMyAdmin privilege i already contacted my host for this so i hope soon i can try this out and give you a feedback on this.

 

Post #7

1. When i have the proper privilege i can turn on the the log and i can trace which query's are slow.

2. I have a SSD

3. My available memory is 8GB

4. My host enabled a caching that saves my website on the server once this page is loaded but it still takes around 6 secondes before a page is loaded.

5. Increased my PHP memory limit to 256 MB

 

Post #9

I enabled this but what information do you need on that page?

 

This is what i can tell you right now about those post.

Link to comment
Share on other sites

Post #7

1. When i have the proper privilege i can turn on the the log and i can trace which query's are slow.

Get the privileges.

 

2. I have a SSD

good.

 

3. My available memory is 8GB

This is probably 2 to 3 times more than you need.

 

4. My host enabled a caching that saves my website on the server once this page is loaded but it still takes around 6 secondes before a page is loaded.

What kind of cache?

 

5. Increased my PHP memory limit to 256 MB

This is enough.

 

Post #9 - I enabled this but what information do you need on that page?

In your screenshot you refered data from your LOGIN page. Which loads in less than 0.1 second. Which is normal. But this is NOT what we want to see. Login is always fast. We want to see screenshots from the actual slow pages but not from the login page.

 

And please post a FULL LIST of your modules. Thanks.

Edited by Scully (see edit history)
Link to comment
Share on other sites

  • 2 weeks later...

I found the problem, the problem was prestashop had to load all of my categories 1 by 1 from topmenu. So i removed this module and my prestashop was really fast. Is there maybe a way to fix this or is it better to search for a module that allows me to make buttons for only the main category and not the subcategories?

Link to comment
Share on other sites

good menu modules will use 'cache'.  they might use their own cache or integrate with native PrestaShop caching. For example Leo Themes use cache/smarty/leobootstrapmenu.

 

It's important to only use 'high quality' theme that has built in menu systems that use cache.  Also then you do not need separate modules for menu creation, i.e. theme has rich set of tools included.  

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...