Open dan-aksenov opened 3 years ago
provide please patroni.yml
and output of sudo ss -luntp |grep 8008
patroni.yml
restapi:
listen: my.host.fqdn:8008
connect_address: my.host.fqdn:8008
I hope it's sufficient, since you require only listen
and certfile
string from config file.
sudo ss -luntp |grep 8008
tcp LISTEN 0 5 ip_address:8008 0.0.0.0:* users:(("python3",pid=24042,fd=8))
also this:
curl -s http://$(hostname):8008
works fine
Changed listen
from fqdn to ip. Seems working
at least getting:
curl -s http://ip:9890/metrics | grep patroni
# HELP patroni_up State of Patroni service: 1 is up, 0 otherwise.
# TYPE patroni_up gauge
patroni_up{service_id="patroni:8008"} 1
pgscv_services_registered_total{service="patroni",service_id="patroni:8008"} 1
But why can't I use fqdn? In out IAC rules fqdns are preffered over IPs.
There is no reason not to use FQDN's. I think this is just a bug/mistake, I will fix it.
got some more errors for patroni monitoring:
{"level":"error","service":"pgscv","time":"2021-09-24T11:07:00+03:00","message":"patroni/common collector failed; parse patroni postmaster_start_time string '2021-09-24 06:22:35.102 MSK' failed: parsing time \"2021-09-24 06:22:35.102 MSK\" as \"2006-01-02 15:04:05.999999Z07:00\": cannot parse \" MSK\" as \"Z07:00\""}
Not sure id it deserves separate issue.
Describe the bug Having troubles with reading patroni metrics:
Steps to reproduce
sudo -u postgres ./pgscv --config-file pgscv.yaml
Also tried running file with root. Also tried running withPATRONI_URL="https://hostname:8008"
exportedExpected behavior No errors and patroni metrics shown in grafana.
pgSCV startup options
Errors and Logs
In Debug mode:
Environment (please complete the following information):
cat /etc/os-release
]pgscv --version
]pgscv 0.7.5 d52f09925a44a67493bd8c598a42c7455e182d5e-release
psql -c 'select version()'
]PostgreSQL 11.8 on x86_64-pc-linux-gnu, compiled by gcc (Ubuntu 7.5.0-3ubuntu1~18.04) 7.5.0, 64-bit
patroni 2.0.2
Additional context None