prometheus-postgresql-adapter icon indicating copy to clipboard operation
prometheus-postgresql-adapter copied to clipboard

failed to connect postgresql

Open jacobawy opened this issue 6 years ago • 2 comments

Hi All, I use the pre-built binaries to push the prometheus data to postgresql issue: err="pq: Ident authentication failed for user "postgres"" but the postgresql is normal, and the user of "postgres" also can be in motion.

I don't know how to solve the problem. Any help would be appreciated.

Regards

jacobawy avatar Oct 09 '18 03:10 jacobawy

Hello,

I just encountered the problem after setting a password for the postgres user.

There should be a configuration file, or better, a .env file to set up the credentials.

Regards,

Knudian avatar Jan 14 '19 12:01 Knudian

After a bit of work - and (re)n reading the doc, I found out how to specify the password.

$ ./prometheus-postgres-adapter -pg.password=PASSWORD

Then, another problem (which I solved on my side), is to make the adapter star on my VM's restart.


On the other hand, having a yaml file for specifying options would be great.

Knudian avatar Jan 16 '19 10:01 Knudian