Skip to content

Latest commit

 

History

History
27 lines (18 loc) · 1.04 KB

README.md

File metadata and controls

27 lines (18 loc) · 1.04 KB

journaldtail

This is a small PoC to explore how to ship journald logs to grafana loki. This code is currently work in progress.

Any comments and suggestions are welcome.

I made this project since the promtail community is not sure if promtail will support journald. (see: grafana/loki#26 (comment) )

Building

To build this, you'll need cgo and the systemd headers installed - for example, on a Debian based system, apt-get install libsystemd-dev.

Journal fields

When you import Journald logs to loki, you'll see a large number of log labels. Its worth reading the systemd journal fields documentation to get a feel for what is available to you.

ToDo

  • Fix logging infrastructure in code
  • Enable configuration via flagext
  • Support relabeling config like in promtail
  • Tests
  • Build and release pipeline
  • Documentation
  • Store journald cursor position on disk to allow restart of journaldtail