Прометей в docker не может перезагрузить файл конфигурации - PullRequest
0 голосов
/ 08 мая 2020

следуя этому руководству https://prometheus.io/docs/prometheus/latest/management_api/

запустите prometheus в docker и добавьте --web.enable-lifecycle

docker run  -d \
  --name prometheus \
  -p 9090:9090 \
  -v /config/prometheus.yml:/etc/prometheus/prometheus.yml  \
  prom/prometheus --web.enable-lifecycle --config.file=/etc/prometheus/prometheus.yml --storage.tsdb.path=/prometheus --web.console.libraries=/usr/share/prometheus/console_libraries --web.console.templates=/usr/share/prometheus/consoles

Я пытаюсь изменить и перезагрузить мою конфигурацию prometheus. файл в docker на

curl -X POST http://??.??.???.??:9090/-/reload

в журналах отображается

root@????:/# docker logs prometheus
level=info ts=2020-05-07T21:00:35.841Z caller=compact.go:441 component=tsdb msg="compact blocks" count=3 mint=1588852800000 maxt=1588874400000 ulid=01E7RF19SZ33YGN335TT7AJ571 sources="[01E7QTE3SVANFH1HPRXS2E07G8 01E7R19V1Y6ECYWKQKTBE6TPCX 01E7R85J9RQZYEMZP04X95ZX5S]" duration=321.581862ms
level=info ts=2020-05-07T23:00:35.949Z caller=compact.go:495 component=tsdb msg="write block" mint=1588881600000 maxt=1588888800000 ulid=01E7RNX0SV98R9ZEMH7EFN611S duration=689.868299ms
level=info ts=2020-05-07T23:00:35.960Z caller=head.go:662 component=tsdb msg="Head GC completed" duration=2.189158ms
level=info ts=2020-05-07T23:00:36.317Z caller=head.go:734 component=tsdb msg="WAL checkpoint complete" first=4 last=5 duration=356.868864ms
level=info ts=2020-05-08T00:17:06.630Z caller=main.go:798 msg="Loading configuration file" filename=/etc/prometheus/prometheus.yml
level=info ts=2020-05-08T00:17:06.631Z caller=main.go:826 msg="Completed loading of configuration file" filename=/etc/prometheus/prometheus.yml

, хотя журнал указывает на успех, на самом деле он неудачный. в чем дело? Вы можете помочь мне? спасибо

...