Closed vitalca closed 2 years ago
This would be a good addition, do you think it is something you could work on?
related: https://github.com/jackc/pgx/commit/5044e8473ad948114b6cb63f6f30f94fc7834667
Hi,
It looks like this was added to the library Telegraf uses here. I tried launching a container with docker run --rm --name postgres --net host -e POSTGRES_USER=postgres -e POSTGRES_PASSWORD=password -e POSTGRES_INITDB_ARGS=--auth-host=scram-sha-256 postgres
and was able to connect successfully:
postgresql,db=postgres,host=ryzen,server=dbname\=postgres\ host\=localhost\ user\=postgres tup_inserted=0i,datname="postgres",sessions_fatal=0i,sessions_abandoned=0i,tup_updated=0i,xact_commit=5i,blk_read_time=0,datid=13757i,deadlocks=0i,blks_read=171i,active_time=0.414,temp_bytes=0i,tup_returned=2907i,numbackends=1i,tup_deleted=0i,blks_hit=3038i,xact_rollback=0i,blk_write_time=0,temp_files=0i,sessions_killed=0i,sessions=2i,session_time=5.272,tup_fetched=1520i,conflicts=0i,idle_in_transaction_time=0 1660678797000000000
postgresql,db=postgres,host=ryzen,server=dbname\=postgres\ host\=localhost\ user\=postgres buffers_alloc=73i,buffers_backend_fsync=0i,checkpoints_req=1i,buffers_clean=0i,checkpoint_write_time=1,buffers_checkpoint=0i,maxwritten_clean=0i,buffers_backend=0i,checkpoint_sync_time=2,checkpoints_timed=0i 1660678797000000000
I'm going to mark this as closed, but if you are still seeing this issue, please do reply and let us know along with how to reproduce and telegraf logs.
Thanks!
Relevant telegraf.conf:
System info:
Steps to reproduce:
pg_hba.conf
Expected behavior:
No issues
Actual behavior:
Temporary workaround:
Configure
trust
authentication for telegraf in thepg_hba.conf