V
V
vyacheslavdmitrievich792018-03-13 06:42:01
MySQL
vyacheslavdmitrievich79, 2018-03-13 06:42:01

How to set up a database connection (symfony 2)?

When opening the site, an error appears:

Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[28000] [1045] Access denied for user 'u27607'@'10.19.0.117' (using password: YES)' in /home/u2600/test.urgeo.ru/ www/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOConnection.php:43 Stack trace: #0 /home/u2600/test.urgeo.ru/www/vendor/doctrine/dbal/lib/Doctrine/DBAL /Driver/PDOConnection.php(43): PDO->__construct('mysql:host=loca...', '****', '****', Array) #1 /home/u2600/test .urgeo.ru/www/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOMySql/Driver.php(45): Doctrine\DBAL\Driver\PDOConnection->__construct('mysql:host=loca... ', '****', '****', Array) #2 /home/u2600/test.urgeo.ru/www/vendor/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(360 ): Doctrine\DBAL\Driver\PDOMySql\Driver->connect(Array, '****', '****', Array) #3 /home/u2600/test.urgeo.ru/www/vendor/doctrine/dbal/lib/Doctrine/DBAL/Connection.php (429): Doctrine\DBAL\Connection->connect() #4 /home/u2600/test.urgeo.ru/www/vendor/doctrine/dbal/lib/Doctrine/DBAL/Connection.ph in /home/u2600/ test.urgeo.ru/www/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/AbstractMySQLDriver.php on line 103

The parameters.yml file contains other connection data (login and password), but it tries to connect using other data.
What could be the problem, where to look? I checked in the config.yml file, everything is fine.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Denis Kruglik, 2018-03-15
@kruglikdenis

Have you tried clearing the cache?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question