Jump to content

No logro reducir el tiempo de respuesta de mi servidor


matiinsi

Recommended Posts

Hola gente! como estan?

 

Luego de buscar muchas soluciones sobre reducir el tiempo de respuesta de mi servidor, no logro hacerlo.

 

He adquirido diversos módulos que me han ayudado en la carga de javascript. También migre a un VPS de hostgator, entre otras cosas que he leído y buscado en el foro y en otras webs.

 

Este es el resultado que Google PageSpeed me ha otorgado:

Reduce server response time
In our test, your server responded in 1.1 seconds. There are many factors that can slow down your server response time.Please read our recommendations to learn how you can monitor and measure where your server is spending the most time.
Lo último que he hecho es poner en "true" la variable _PS_DEBUG_PROFILING_ y esto es lo que me informa:
Load time828ms
I hope it is a shared hosting
  • config: 120ms
  • constructor: 0ms
  • init: 61ms
  • checkAccess: 0ms
  • setMedia: 3ms
  • postProcess: 0ms
  • initHeader: 0ms
  • initContent: 518ms
  • initFooter: 55ms
  • display: 70ms

 

Hook processing580ms / 11.34 Mb

  • displayRightColumn: 185ms / 3.12 Mb
  • displayTop: 157ms / 2.25 Mb
  • displayHeader: 110ms / 4.3 Mb
  • displayHome: 66ms / 0.57 Mb
  • displayFooter: 55ms / 0.81 Mb
  • moduleRoutes: 7ms / 0.29 Mb
  • actionFrontControllerSetMedia: 0ms / 0 Mb
  • DisplayOverrideTemplate: 0ms / 0 Mb
  • displayMyAccountBlockfooter: 0ms / 0 Mb
  • actionDispatcher: 0ms / 0 Mb
  • displayLeftColumn: 0ms / 0 Mb
  • actionObjectUpdateAfter: 0ms / 0 Mb
  • actionObjectUpdateBefore: 0ms / 0 Mb
  • actionObjectCartUpdateAfter: 0ms / 0 Mb
  • actionObjectCartUpdateBefore: 0ms / 0 Mb
  • actionCartSave: 0ms / 0 Mb

 

Memory peak usage20.7 Mb

  • config: 5.81 Mb (5.9 Mb)
  • constructor: 0 Mb (5.9 Mb)
  • init: 3.17 Mb (9 Mb)
  • checkAccess: 0 Mb (9 Mb)
  • setMedia: 0.15 Mb (9.2 Mb)
  • postProcess: 0 Mb (9.2 Mb)
  • initHeader: 0.01 Mb (9.2 Mb)
  • initContent: 10.27 Mb (19.7 Mb)
  • initFooter: 0.82 Mb (20.5 Mb)
  • display: 0.15 Mb (20.7 Mb)

 

DB type: DbPDO 
SQL Queries229 queries 
Time spent querying88ms

 

Included files: 198

Size of included files2.34 Mb

 

Globals (> 1 Ko only): 513 Ko

  • _LANG ≈ 224.8 Ko
  • _MODULES ≈ 168.2 Ko
  • context ≈ 59.8 Ko
  • _MODULE ≈ 23.3 Ko
  • _SERVER ≈ 8.9 Ko
  • smarty ≈ 7.7 Ko
  • _ENV ≈ 7.7 Ko
  • _REQUEST ≈ 3.8 Ko
  • _COOKIE ≈ 3.8 Ko

 

Stopwatch (with SQL_NO_CACHE) (total = 229)

7.895 ms SELECT SQL_NO_CACHE t.name, COUNT(pt.id_tag) AS times FROM `ps_product_tag` pt LEFT JOIN `ps_tag` t ON (t.id_tag = pt.id_tag) LEFT JOIN `ps_product` p ON (p.id_product = pt.id_product) INNER JOIN ps_product_shop product_shop ON (product_shop.id_product = p.id_product AND product_shop.id_shop = 1) WHERE t.`id_lang` = 1 AND product_shop.`active` = 1 AND product_shop.`id_product` IN ( SELECT cp.`id_product` FROM `ps_category_group` cg LEFT JOIN `ps_category_product` cp ON (cp.`id_category` = cg.`id_category`) WHERE cg.`id_group` IN (3) ) GROUP BY t.id_tag ORDER BY times DESC LIMIT 0, 10
in /home/floresda/public_html/classes/Tag.php:152
USING FILESORT - 357 rows browsed

5.406 ms SELECT SQL_NO_CACHE p.*, product_shop.*, stock.out_of_stock, IFNULL(stock.quantity, 0) as quantity, MAX(product_attribute_shop.id_product_attribute) id_product_attribute, product_attribute_shop.minimal_quantity AS product_attribute_minimal_quantity, pl.`description`, pl.`description_short`, pl.`available_now`, pl.`available_later`, pl.`link_rewrite`, pl.`meta_description`, pl.`meta_keywords`, pl.`meta_title`, pl.`name`, MAX(image_shop.`id_image`) id_image, il.`legend`, m.`name` AS manufacturer_name, cl.`name` AS category_default, DATEDIFF(product_shop.`date_add`, DATE_SUB(NOW(), INTERVAL 20 DAY)) > 0 AS new, product_shop.price AS orderprice FROM `ps_category_product` cp LEFT JOIN `ps_product` p ON p.`id_product` = cp.`id_product` INNER JOIN ps_product_shop product_shop ON (product_shop.id_product = p.id_product AND product_shop.id_shop = 1) LEFT JOIN `ps_product_attribute` pa ON (p.`id_product` = pa.`id_product`) LEFT JOIN ps_product_attribute_shop product_attribute_shop ON (product_attribute_shop.id_product_attribute = pa.id_product_attribute AND product_attribute_shop.id_shop = 1 AND product_attribute_shop.`default_on` = 1) LEFT JOIN ps_stock_available stock ON (stock.id_product = p.id_product AND stock.id_product_attribute = IFNULL(`product_attribute_shop`.id_product_attribute, 0) AND stock.id_shop = 1 ) LEFT JOIN `ps_category_lang` cl ON (product_shop.`id_category_default` = cl.`id_category` AND cl.`id_lang` = 1 AND cl.id_shop = 1 ) LEFT JOIN `ps_product_lang` pl ON (p.`id_product` = pl.`id_product` AND pl.`id_lang` = 1 AND pl.id_shop = 1 ) LEFT JOIN `ps_image` i ON (i.`id_product` = p.`id_product`) LEFT JOIN ps_image_shop image_shop ON (image_shop.id_image = i.id_image AND image_shop.id_shop = 1 AND image_shop.cover=1) LEFT JOIN `ps_image_lang` il ON (image_shop.`id_image` = il.`id_image` AND il.`id_lang` = 1) LEFT JOIN `ps_manufacturer` m ON m.`id_manufacturer` = p.`id_manufacturer` WHERE product_shop.`id_shop` = 1 AND cp.`id_category` = 2 AND product_shop.`active` = 1 AND product_shop.`visibility` IN ("both", "catalog") GROUP BY product_shop.id_product ORDER BY cp.`position` ASC LIMIT 0,8
in /home/floresda/public_html/classes/Category.php:659
USING FILESORT - 8 rows browsed

2.449 ms SELECT SQL_NO_CACHE p.id_product, pl.`link_rewrite`, pl.`name`, pl.`description_short`, MAX(image_shop.`id_image`) id_image, il.`legend`, ps.`quantity` AS sales, p.`ean13`, p.`upc`, cl.`link_rewrite` AS category, p.show_price, p.available_for_order, p.quantity, p.customizable, IFNULL(pa.minimal_quantity, p.minimal_quantity) as minimal_quantity, p.out_of_stock FROM `ps_product_sale` ps LEFT JOIN `ps_product` p ON ps.`id_product` = p.`id_product` INNER JOIN ps_product_shop product_shop ON (product_shop.id_product = p.id_product AND product_shop.id_shop = 1) LEFT JOIN `ps_product_attribute` pa ON (ps.`id_product` = pa.`id_product` AND pa.default_on = 1) LEFT JOIN `ps_product_lang` pl ON p.`id_product` = pl.`id_product` AND pl.`id_lang` = 1 AND pl.id_shop = 1 LEFT JOIN `ps_image` i ON (i.`id_product` = p.`id_product`) LEFT JOIN ps_image_shop image_shop ON (image_shop.id_image = i.id_image AND image_shop.id_shop = 1 AND image_shop.cover=1) LEFT JOIN `ps_image_lang` il ON (i.`id_image` = il.`id_image` AND il.`id_lang` = 1) LEFT JOIN `ps_category_lang` cl ON cl.`id_category` = product_shop.`id_category_default` AND cl.`id_lang` = 1 AND cl.id_shop = 1 WHERE product_shop.`active` = 1 AND p.`visibility` != 'none' AND p.`id_product` IN (8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,59,60,61,62,63,64,65,66,67,68,69,70,72,73,74,75,76,77,78,79,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,99,100,102,103,104,105,106,107,108,109,110,112,113,114,115,116,117,118,119,120,122,123,124,125,126,127,128,129,131,132,133,134,135,136,137,138,139,140,141,142,143) GROUP BY product_shop.id_product ORDER BY sales DESC LIMIT 0, 5
in /home/floresda/public_html/classes/ProductSale.php:188
USING FILESORT - 11 rows browsed

2.306 ms SELECT SQL_NO_CACHE c.`name`, cl.`id_lang`, IF(cl.`id_lang` IS NULL, c.`value`, cl.`value`) AS value, c.id_shop_group, c.id_shop FROM `ps_configuration` c LEFT JOIN `ps_configuration_lang` cl ON (c.id_configuration = cl.id_configuration)
in /home/floresda/public_html/classes/Configuration.php:116
708 rows browsed

2.118 ms SELECT SQL_NO_CACHE h.id_hook, h.name as h_name, title, description, h.position, live_edit, hm.position as hm_position, m.id_module, m.name, active FROM `ps_hook` h INNER JOIN `ps_hook_module` hm ON (h.id_hook = hm.id_hook AND hm.id_shop = 1) INNER JOIN `ps_module` as m ON (m.id_module = hm.id_module) ORDER BY hm.position
in /home/floresda/public_html/classes/Hook.php:227
USING FILESORT - 53 rows browsed

1.822 ms SELECT SQL_NO_CACHE p.*, product_shop.*, stock.out_of_stock, IFNULL(stock.quantity, 0) as quantity, pl.`description`, pl.`description_short`, pl.`link_rewrite`, pl.`meta_description`, pl.`meta_keywords`, pl.`meta_title`, pl.`name`, MAX(image_shop.`id_image`) id_image, il.`legend`, m.`name` AS manufacturer_name, product_shop.`date_add` > "2014-08-25" as new, MAX(product_attribute_shop.id_product_attribute) id_product_attribute FROM `ps_product` p INNER JOIN ps_product_shop product_shop ON (product_shop.id_product = p.id_product AND product_shop.id_shop = 1) LEFT JOIN `ps_product_lang` `pl` ON p.`id_product` = pl.`id_product` AND pl.`id_lang` = 1 AND pl.id_shop = 1 LEFT JOIN `ps_image` `i` ON i.`id_product` = p.`id_product` LEFT JOIN ps_image_shop image_shop ON (image_shop.id_image = i.id_image AND image_shop.id_shop = 1 AND image_shop.cover=1) LEFT JOIN `ps_image_lang` `il` ON i.`id_image` = il.`id_image` AND il.`id_lang` = 1 LEFT JOIN `ps_manufacturer` `m` ON m.`id_manufacturer` = p.`id_manufacturer` LEFT OUTER JOIN `ps_product_attribute` pa ON p.`id_product` = pa.`id_product` LEFT JOIN ps_product_attribute_shop product_attribute_shop ON (product_attribute_shop.id_product_attribute = pa.id_product_attribute AND product_attribute_shop.id_shop = 1 AND product_attribute_shop.default_on = 1) LEFT JOIN ps_stock_available stock ON (stock.id_product = p.id_product AND stock.id_product_attribute = IFNULL(`product_attribute_shop`.id_product_attribute, 0) AND stock.id_shop = 1 ) WHERE (product_shop.`active` = 1) AND (product_shop.`visibility` IN ("both", "catalog")) AND (product_shop.`date_add` > "2014-08-25") AND (p.`id_product` IN ( SELECT cp.`id_product` FROM `ps_category_group` cg LEFT JOIN `ps_category_product` cp ON (cp.`id_category` = cg.`id_category`) WHERE cg.`id_group` IN (3) )) GROUP BY product_shop.id_product ORDER BY p.`date_add` DESC LIMIT 5
in /home/floresda/public_html/classes/Product.php:2084
USING FILESORT - 2 rows browsed

1.437 ms SELECT SQL_NO_CACHE `id_hook`, `name` FROM `ps_hook` UNION SELECT `id_hook`, ha.`alias` as name FROM `ps_hook_alias` ha INNER JOIN `ps_hook` h ON ha.name = h.name
in /home/floresda/public_html/classes/Hook.php:130
0 rows browsed

1.411 ms SELECT SQL_NO_CACHE h.`name` as hook, m.`id_module`, h.`id_hook`, m.`name` as module, h.`live_edit` FROM `ps_module` m INNER JOIN `ps_hook_module` hm ON hm.`id_module` = m.`id_module` INNER JOIN `ps_hook` h ON hm.`id_hook` = h.`id_hook` LEFT JOIN `ps_module_group` `mg` ON mg.`id_module` = m.`id_module` WHERE ((SELECT COUNT(*) FROM ps_module_shop ms WHERE ms.id_module = m.id_module AND ms.id_shop IN (1)) = 1) AND (h.name != "displayPayment") AND (hm.id_shop = 1) AND (mg.id_shop = 1 AND mg.`id_group` IN (3)) GROUP BY hm.id_hook, hm.id_module ORDER BY hm.`position`
in /home/floresda/public_html/classes/Hook.php:339
USING FILESORT - 53 rows browsed

 

Por lo que puedo observar el problema es que tarda mucho en las consultas de la base de datos. Vi que el modo Cache de mysql está activo. Por lo tanto ya no se que más puedo realizar para aumentar la respuesta de mi servidor. 

Mi servidor VPS no soporta memcached ni APS. Pero si Xcache. Lo he instalado pero al momento de poner en "true" la variable _PS_DEBUG_PROFILING_ me da un error de " XCache: Cannot init". Por lo tanto lo he desactivado.

 

¿Alguna ayuda que puedan brindarme? Desde ya, gracias por su tiempo.

 

Saludos!

 

Link to comment
Share on other sites

  • 4 weeks later...
  • nadie locked this topic
Guest
This topic is now closed to further replies.
×
×
  • Create New...