[Bitrix\Main\DB\SqlQueryException] 
Mysql query error: (2006) MySQL server has gone away (400)
SELECT 
	`sale_internals_discount_entities`.`ID` AS `ID`,
	`sale_internals_discount_entities_active_discount`.`ID` AS `UALIAS_0`
FROM `b_sale_discount_entities` `sale_internals_discount_entities` 
LEFT JOIN `b_sale_discount` `sale_internals_discount_entities_active_discount` ON `sale_internals_discount_entities`.`DISCOUNT_ID` = `sale_internals_discount_entities_active_discount`.`ID`
WHERE `sale_internals_discount_entities`.`MODULE_ID` = 'catalog'
AND `sale_internals_discount_entities`.`ENTITY` = 'PRICE'
AND `sale_internals_discount_entities`.`FIELD_ENTITY` = 'CATALOG_GROUP_ID'
AND `sale_internals_discount_entities`.`FIELD_TABLE` = 'CATALOG_GROUP_ID'
AND `sale_internals_discount_entities_active_discount`.`ACTIVE` = 'Y'
LIMIT 0, 1

/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/lib/db/mysqliconnection.php:137
#0: Bitrix\Main\DB\MysqliConnection->queryInternal(string, array, NULL)
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/lib/db/connection.php:330
#1: Bitrix\Main\DB\Connection->query(string)
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/lib/orm/query/query.php:3306
#2: Bitrix\Main\ORM\Query\Query->query(string)
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/lib/orm/query/query.php:817
#3: Bitrix\Main\ORM\Query\Query->exec()
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/lib/orm/data/datamanager.php:500
#4: Bitrix\Main\ORM\Data\DataManager::getList(array)
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/catalog/general/product.php:2522
#5: CAllCatalogProduct::initSaleSettings()
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/catalog/general/product.php:1089
#6: CAllCatalogProduct::GetOptimalPrice(integer, double, array, string, array, string, array)
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/components/bitrix/catalog.element/class.php:138
#7: CatalogElementComponent->initAdditionalCacheKeys(array)
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/iblock/lib/component/element.php:775
#8: Bitrix\Iblock\Component\Element->getCacheKeys()
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/iblock/lib/component/base.php:4021
#9: Bitrix\Iblock\Component\Base->initResultCache()
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/iblock/lib/component/base.php:4560
#10: Bitrix\Iblock\Component\Base->loadData()
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/iblock/lib/component/base.php:4540
#11: Bitrix\Iblock\Component\Base->initialLoadAction()
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/iblock/lib/component/element.php:271
#12: Bitrix\Iblock\Component\Element->initialLoadAction()
	
#13: call_user_func(array)
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/iblock/lib/component/base.php:4725
#14: Bitrix\Iblock\Component\Base->doAction()
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/iblock/lib/component/base.php:4743
#15: Bitrix\Iblock\Component\Base->executeComponent()
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/classes/general/component.php:649
#16: CBitrixComponent->includeComponent(string, array, object)
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/classes/general/main.php:1039
#17: CAllMain->IncludeComponent(string, string, array, object)
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/templates/pin_avto/components/bitrix/catalog/catalog-pin/element.php:244
#18: include(string)
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/classes/general/component_template.php:789
#19: CBitrixComponentTemplate->__IncludePHPTemplate(array, array, string)
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/classes/general/component_template.php:884
#20: CBitrixComponentTemplate->IncludeTemplate(array)
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/classes/general/component.php:746
#21: CBitrixComponent->showComponentTemplate()
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/classes/general/component.php:694
#22: CBitrixComponent->includeComponentTemplate(string)
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/components/bitrix/catalog/component.php:171
#23: include(string)
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/classes/general/component.php:605
#24: CBitrixComponent->__includeComponent()
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/classes/general/component.php:664
#25: CBitrixComponent->includeComponent(string, array, boolean)
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/classes/general/main.php:1039
#26: CAllMain->IncludeComponent(string, string, array, boolean)
	/var/www/pin-avto/data/www/abinsk.pin-avto.ru/catalog/index.php:321
#27: include_once(string)
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/include/urlrewrite.php:159
#28: include_once(string)
	/var/www/pin-avto/data/www/pin-avto2.ru/bitrix/urlrewrite.php:3

Fatal error: Uncaught Bitrix\Main\DB\SqlQueryException: Mysql query error: (2006) MySQL server has gone away in /var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/lib/db/mysqliconnection.php:137 Stack trace: #0 /var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/lib/db/connection.php(330): Bitrix\Main\DB\MysqliConnection->queryInternal('SELECT \n\t`main_...', Array, NULL) #1 /var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/lib/orm/query/query.php(3306): Bitrix\Main\DB\Connection->query('SELECT \n\t`main_...') #2 /var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/lib/orm/query/query.php(817): Bitrix\Main\ORM\Query\Query->query('SELECT \n\t`main_...') #3 /var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/lib/orm/data/datamanager.php(500): Bitrix\Main\ORM\Query\Query->exec() #4 /var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/lib/analytics/sitespeed.php(95): Bitrix\Main\ORM\Data\DataManager::getList(Array) #5 /var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/ in /var/www/pin-avto/data/www/pin-avto2.ru/bitrix/modules/main/lib/db/mysqliconnection.php on line 137