SideCar logging

13 views
Skip to first unread message

Saurabh Jain

unread,
May 22, 2020, 5:00:55 AM5/22/20
to Prometheus Users
Hi Guys,

Is it possible to pass log path as a parameter while running Thanos components like for eg if we are running Sidecar via below command.

thanos sidecar --http-address 127.0.0.1:19090   --grpc-address  127.0.0.1:19091  --prometheus.url http://localhost:9090 --log.level=info --log.format=logfmt

Idea is to create log file in directory for eg /opt/prometheus/sidecar.log while running Sidecar command.

Pls advice.

Thanks,
Saurabh

Julius Volz

unread,
May 22, 2020, 6:27:09 AM5/22/20
to Saurabh Jain, Prometheus Users
Hi,

the Thanos components (like Prometheus itself) can only log to stderr, so if you want to capture logs in a file, you will have to solve this externally (e.g. via systemd or whatever process supervisor / runtime environment you are using).

Regards,
Julius

--
You received this message because you are subscribed to the Google Groups "Prometheus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to prometheus-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/prometheus-users/55511dce-1837-4f93-98c9-600a12b907b3%40googlegroups.com.


--
Julius Volz
PromLabs - promlabs.com

Saurabh Jain

unread,
May 22, 2020, 8:08:44 AM5/22/20
to Prometheus Users

Thanks Julius . Got it.

On Friday, May 22, 2020 at 3:57:09 PM UTC+5:30, Julius Volz wrote:
Hi,

the Thanos components (like Prometheus itself) can only log to stderr, so if you want to capture logs in a file, you will have to solve this externally (e.g. via systemd or whatever process supervisor / runtime environment you are using).

Regards,
Julius

On Fri, May 22, 2020 at 11:00 AM Saurabh Jain <s.saura...@gmail.com> wrote:
Hi Guys,

Is it possible to pass log path as a parameter while running Thanos components like for eg if we are running Sidecar via below command.

thanos sidecar --http-address 127.0.0.1:19090   --grpc-address  127.0.0.1:19091  --prometheus.url http://localhost:9090 --log.level=info --log.format=logfmt

Idea is to create log file in directory for eg /opt/prometheus/sidecar.log while running Sidecar command.

Pls advice.

Thanks,
Saurabh

--
You received this message because you are subscribed to the Google Groups "Prometheus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to promethe...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages