mám problém s databazí – refused connection

JBurdik
Člen | 10
+
0
-

Nějaké řešení jsem docela začátečník.

Nette\Database\ConnectionException #HY000

SQLSTATE[HY000] [2002] Connection refused search►
Caused by PDOException
Source file
Call stack
.../vendor/nette/database/src/Database/Connection.php:73	source  Nette\Database\DriverException::from(arguments)

.../vendor/nette/database/src/Database/Connection.php:118	source  Nette\Database\Connection->connect()

.../vendor/nette/database/src/Database/Structure.php:196	source  Nette\Database\Connection->getSupplementalDriver()

inner-code	Nette\Database\Structure->loadStructure(arguments)

.../vendor/nette/caching/src/Caching/Cache.php:94	source  call_user_func_array(arguments)

inner-code	Nette\Caching\Cache->Nette\Caching\{closure}(arguments)

.../vendor/nette/caching/src/Caching/Cache.php:174	source  call_user_func_array(arguments)

.../vendor/nette/caching/src/Caching/Cache.php:95	source  Nette\Caching\Cache->save(arguments)

.../vendor/nette/database/src/Database/Structure.php:187	source  Nette\Caching\Cache->load(arguments)

.../vendor/nette/database/src/Database/Structure.php:58	source  Nette\Database\Structure->needStructure()

.../src/Database/Conventions/DiscoveredConventions.php:31	source  Nette\Database\Structure->getPrimaryKey(arguments)

.../nette/database/src/Database/Table/Selection.php:95	source  Nette\Database\Conventions\DiscoveredConventions->getPrimary(arguments)

.../vendor/nette/database/src/Database/Context.php:101	source  Nette\Database\Table\Selection->__construct(arguments)

.../sub/citylife/app/model/NewsRepository.php:20	source  Nette\Database\Context->table(arguments)

10:        public function __construct(Nette\Database\Context $database) {
11:            $this->database = $database;
12:        }
13:
14:        const TABLE = 'news';
15:
16:        /**
17:         * @return bool|mixed|\Nette\Database\Table\IRow
18:         */
19:        public function fetchAll() {
20:            return $this->database->table(self::TABLE)->order("id ASC")->fetchAll();
21:        }
22:
23:        /**
24:         * @param $id
.../FrontendModule/presenters/HomepagePresenter.php:21	source  NewsRepository->fetchAll()

inner-code	FrontendModule\HomepagePresenter->renderDefault()

.../nette/application/src/Application/UI/Component.php:92	source  ReflectionMethod->invokeArgs(arguments)

.../nette/application/src/Application/UI/Presenter.php:214	source  Nette\Application\UI\Component->tryCall(arguments)

.../nette/application/src/Application/Application.php:145	source  Nette\Application\UI\Presenter->run(arguments)

.../nette/application/src/Application/Application.php:83	source  Nette\Application\Application->processRequest(arguments)

.../jiriburdych/netaxe.cz/sub/citylife/www/index.php:6	source  Nette\Application\Application->run()

Editoval JBurdik (6. 12. 2018 17:23)

Petr Parolek
Člen | 455
+
0
-

taková chyba nemá zřejmě souvislost s Nette. Máš správý db host v config a běží ti mysql server?