I am unable to connect using psql
to PostgreSQL 9.6 on Windows 10. I saw almost all the StackExchange questions regarding this error. While installing Postgres it asked for superuser password and I set it. Added host all all 0.0.0.0/0 trust
and host all all ::0/0 trust
to pg_hba.conf
but still no luck. This is the pg_hba.conf
contents on my machine:
host all all localhost trust
host all all 127.0.0.1/32 trust
IPv6 local connections:
host all all ::1/128 trust
host all all ::0/0 trust
host all all 0.0.0.0/0 trust
Any help would be appreciated.
psql -h 127.0.0.1 -U postgres -d postgres
i tried to give thisThe pg_hba.conf file is read on start-up and when the main server process receives a SIGHUP signal. If you edit the file on an active system, you will need to signal the postmaster (using pg_ctl reload or kill -HUP) to make it re-read the file.
Did you restart?