Table of Contents
I used to get an error SCRAM authentication requires libpq version 10 or above when running php artisan migrate
in laravel 8
. Then I fixed it as follows: Change authentication from scram-sha-256
to md5
, then reset your password
and restart the postgresql-x64-13 service
and here are step by step:
-
Step 1: Find file
postgresql.conf
inC:\Program Files\PostgreSQL\13\data
then setpassword_encryption = md5
-
Step 2: Find file
pg_hba.conf
inC:\Program Files\PostgreSQL\13\data
then change allMETHOD
tomd5
-
Step 3: Open
command line (cmd,cmder,git bash...)
and runpsql -U postgres
then enter your password when installed postgres sql - Step 4: Then change your password by run
ALTER USER postgres WITH PASSWORD 'new-password'
in command line
ALTER USER postgres WITH PASSWORD 'new-password';
- Final: Restart service
postgresql-x64-13
in yourService
.
postgresql.conf
Fix to
pg_hba.conf
Fix to