Hi Anders,
Thanks for sharing the information, it was helpful.
I looked at the ESS repos on GitLab and tried something similar with success. I set up caPutLog to send messages to a syslog-ng source, which then forwards it to Loki via Grafana Alloy (Promtail's replacement). I had some trouble getting Alloy to work inside a container, so for the proof of concept I deployed it as a systemd service directly on the machine running the IOC. I now need to look at what the issue was with the containerised setup, but I can continue my work from this.
Best regards,
Afonso
________________________________________
De: Anders Lindh Olsson <anders.lindholsson at ess.eu>
Enviado: terça-feira, 10 de fevereiro de 2026 04:28
Para: Afonso Haruo Carnielli Mukai; tech-talk at aps.anl.gov
Assunto: Re: How to send caPutLog logs to Grafana Loki
Hello Afonso,
We stream the putlog as well as procserv log, conserver log, etc. to Grafana Loki using syslog-ng. Look at our ansible role for IOC deployment and then for syslog-ng – I think you will be able to find those in our GitLab instance. I do, unfortunately, not know how Grafana Loki is configured after this; I am pretty sure Promtail used to be involved but I do not know if it is anymore. The latter parts – closer to Grafana loki and graylog – are managed by our IT or infrastructure group(s), but maybe you can reach out to some names you know there?
HTH
A
From: Tech-talk <tech-talk-bounces at aps.anl.gov> on behalf of Afonso Haruo Carnielli Mukai via Tech-talk <tech-talk at aps.anl.gov>
Date: Monday, 9 February 2026 at 19:54
To: tech-talk at aps.anl.gov <tech-talk at aps.anl.gov>
Subject: How to send caPutLog logs to Grafana Loki
Hi,
I'm working on a proof of concept for sending IOC PV put logs to a logging server using caPutLog and Grafana Loki. I'm new to Loki, but my understanding is that it only accepts logs via the HTTP API, different from something like Graylog where you can configure inputs in different formats.
Is anyone using caPutLog and Loki? If so, how do you forward the logs to the server? After some discussions with people working with EPICS here, I can think of the following options:
1. Implement client-side code on the IOC to send directly to Loki (seems to be more work than the other options)
2. Implement a simple server that receives the logs from caPutLog and sends it to Loki
3. (Not sure caPutLog supports this) Get the IOC logs to the system journal/container logs (the IOCs in question are containerised) and then use Grafana Alloy to send them to Loki - is it possible to configure caPutLog to just print the logs to the console, without setting a server?
If anyone has experience or thoughts on this, comments and suggestions are appreciated.
Best regards,
Afonso Mukai
Brazilian Synchrotron Light Laboratory
Aviso Legal: Esta mensagem e seus anexos podem conter informações confidenciais e/ou de uso restrito. Observe atentamente seu conteúdo e considere eventual consulta ao remetente antes de copiá-la, divulgá-la ou distribuí-la. Se você recebeu esta mensagem por engano, por favor avise o remetente e apague-a imediatamente.
Disclaimer: This email and its attachments may contain confidential and/or privileged information. Observe its content carefully and consider possible querying to the sender before copying, disclosing or distributing it. If you have received this email by mistake, please notify the sender and delete it immediately.
- References:
- How to send caPutLog logs to Grafana Loki Afonso Haruo Carnielli Mukai via Tech-talk
- Re: How to send caPutLog logs to Grafana Loki Anders Lindh Olsson via Tech-talk
- Navigate by Date:
- Prev:
Re: Support for piezo controller nanoFAKTUR EBD-060310 Torsten Bögershausen via Tech-talk
- Next:
Re: How to use the RVEL field of the motor record Mark Rivers via Tech-talk
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
<2026>
- Navigate by Thread:
- Prev:
Re: How to send caPutLog logs to Grafana Loki Anders Lindh Olsson via Tech-talk
- Next:
Question: CA monitor event and timestamp handling on compress record reset Kim, Kukhee via Tech-talk
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
<2026>
|