DEV Community

CharlieSchwab
CharlieSchwab

Posted on

Postgres Authentication Problem

Hello, everyone.
I'm new to this community. I don't know if my first post should have been an introduction of myself.
But currently I've got a pressing matter at hand.
I've searched stackoverflow and almost all documents google could provide. Still my problem is unsolved.
I'm trying to run a server on VPS.
The user and database is created. And I've configured the authentication method into md5 in the following file.

/etc/postgresql/12/main/pg_hba.conf

Yet, when I try to login with the following URL, I get an error
[password authentication failed for user "username"]

DATABASE_URL=postgres://username:@localhost/dbname

Please help me solve this problem.

Top comments (0)