samedi 24 décembre 2016

sqlstate[hy000] [2002] connection refused in laravel 5.2.29 trying php artisan migrate

I'm trying to execute migrations in my laravel_cms database

mysql> show databases;

+--------------------+ | Database | +--------------------+ | information_schema | | laravel_cms | | mysql | | performance_schema | | tallerPHP | +--------------------+ 5 rows in set (0,00 sec)

I put the correct parameters in the .env file in my project DB_CONNECTION=mysql DB_HOST=127.0.0.1 DB_PORT=8889 DB_DATABASE=laravel_cms DB_USERNAME=root DB_PASSWORD=password

The default password in MAMP PRO to root user is root but I have changed it. But that is not a problem because I access using terminal with tag password

The port than MAMP PRO uses is 8889

But when I execute this command in the larval project: php artisan migrate

I get this error [PDOException]
SQLSTATE[HY000] [2002] Connection refused

Any idea please?

Regards



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire