PrestaShopException {#18
#message: "Link to database cannot be established: SQLSTATE[HY000] [2002] Connection refused"
#code: 0
#file: "/var/www/html/s-e/classes/db/DbPDO.php"
#line: 136
trace: {
/var/www/html/s-e/classes/db/DbPDO.php:136 {
› } catch (PDOException $e) {
› throw new PrestaShopException('Link to database cannot be established: ' . $e->getMessage());
› }
}
/var/www/html/s-e/classes/db/Db.php:379 {
› if (!$this->result && $this->getNumberError() == 2006) {
› if ($this->connect()) {
› $this->result = $this->_query($sql);
}
/var/www/html/s-e/classes/db/Db.php:663 {
›
› $this->result = $this->query($sql);
› if (!$this->result) {
arguments: {
$sql: """
SELECT *\n
FROM `sk_country` a\n
LEFT JOIN `sk_country_lang` `b` ON a.`id_country` = b.`id_country` AND b.`id_lang` = 1\n
LEFT JOIN `sk_country_shop` `c` ON a.`id_country` = c.`id_country` AND c.`id_shop` = 1\n
WHERE (a.`id_country` = 208) LIMIT 1
"""
}
}
/var/www/html/s-e/src/Adapter/EntityMapper.php:76 {
›
› if ($object_datas = Db::getInstance()->getRow($sql)) {
› $objectVars = get_object_vars($entity);
arguments: {
$sql: """
SELECT *\n
FROM `sk_country` a\n
LEFT JOIN `sk_country_lang` `b` ON a.`id_country` = b.`id_country` AND b.`id_lang` = 1\n
LEFT JOIN `sk_country_shop` `c` ON a.`id_country` = c.`id_country` AND c.`id_shop` = 1\n
WHERE (a.`id_country` = 208) LIMIT 1
"""
}
}
/var/www/html/s-e/classes/ObjectModel.php:265 {
› $entity_mapper = ServiceLocator::get('\\PrestaShop\\PrestaShop\\Adapter\\EntityMapper');
› $entity_mapper->load($id, $this->id_lang, $this, $this->def, $this->id_shop, self::$cache_objects);
› }
arguments: {
$id: "208"
$id_lang: "1"
$entity: Country {#15 …}
$entity_defs: array:6 [ …6]
$id_shop: 1
$should_cache_objects: true
}
}
/var/www/html/s-e/config/config.inc.php:157 {
› /* Loading default country */
› $default_country = new Country(Configuration::get('PS_COUNTRY_DEFAULT'), Configuration::get('PS_LANG_DEFAULT'));
› $context->country = $default_country;
arguments: {
$id: "208"
$id_lang: "1"
}
}
/var/www/html/s-e/index.php:28 {
›
› require dirname(__FILE__).'/config/config.inc.php';\r
› Dispatcher::getInstance()->dispatch();\r
arguments: {
"/var/www/html/s-e/config/config.inc.php"
}
}
}
}