I did setup Postgres-12 on Centos AMI EC2, It works well.
However, Sometimes (my case is the next day) I can not connect my DB by trying
$psql -h XXXX -p5432 -Upostgres
A authentication failed error
psql: error: could not connect to server: FATAL: password authentication failed for user "postgres"
Next, I change my postgres user again by
$sudo su - postgres ~]$ psql -c "alter user postgres with password 'postgres'"
The connection login become work.
- But sometimes it become not work again (same above authentication failed) I reset postgres password the same above command => The connection login become work.
- It repeats #2
I don't know why. Does anybody know that? What should I do?
