jeudi 19 juillet 2018

Laravel 5.6 cannot connect to database after clearing cache

i cannot connect to database after clearing even php artisan is not working. here is how i clear config caches:

php artisan cache:clear

then it's cleared successfully but when i run:

php artisan config:cache

i got this error:

<pre><strong>ERROR:</strong> Can't connect to the database server. SQLSTATE[HY000] [1045] Access denied for user ''@'localhost' (using password: NO)</pre>% 

i also tried: composer dump-autoload but still no luck. Once in the past i got same error and i was able to solve it but no idea how. If someone knows solution then kindly explain it as well.

My php version: PHP 7.2.5-1+ubuntu18.04.1+deb.sury.org+1 (cli) (built: May 5 2018 05:00:15) ( NTS )

Thank you!



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire