RousselTMLEARNING

TP · Alloy: From Discovery to Expertise

Hands-on: Collecting and Dispatching Logs to Loki

Introduction #

The goal of this lab is to configure Grafana Alloy to read local log files, add context labels, and send them to a Grafana Loki instance.

Log Pipeline #

We will configure the blocks composing the pipeline in River language.

  1. 1. Log Source

    Add configuration to discover and read `/var/log/myapp/*.log` files.

  2. 2. Log Processing

    Add a processing block to dynamically add an `env=production` label to all collected log lines.

  3. 3. Dispatching to Loki

    Configure sending logs to a Loki instance available at `http://localhost:3100`.

Difficulty level : ●●○○○ (2/5)

My progress

  • ⏱ Estimated time : ≈ 21 min

Sign in to track your progress and take notes. Sign in

💬 Ask a question

Course Glossary

Grafana Alloy

An open-source, vendor-neutral telemetry collector designed to replace Grafana Agent, fully compatible with OpenTelemetry (OTel).

Recommended Articles

Grafana Alloy: Log Management with Loki

Discover how to configure Grafana Alloy to read log files, journald, or network streams, process ...

Grafana Alloy : Collecte et Transformation de Télémétrie

Apprenez à utiliser Grafana Alloy pour collecter, transformer et acheminer logs, métriques et tra...

La stack LGTM (Loki, Grafana, Tempo, Mimir) : architecture et mise en place

Comprendre la stack LGTM de Grafana Labs : Loki pour les logs, Grafana pour la visualisation, Tem...

Référence des Composants Grafana Alloy

Un guide de référence complet sur tous les composants disponibles dans Grafana Alloy, organisé pa...

Collecter des logs vers Loki : Alloy, Promtail, Docker et OpenTelemetry

Envoyer des logs vers Loki : Grafana Alloy, Promtail, driver Docker, OTLP, bons labels, parsing e...

Grafana Alloy: The importance of Self-Monitoring

Discover why and how to configure Grafana Alloy so that it monitors itself, collecting its own lo...

Grafana Alloy : Collecter les métriques système et les logs locaux

Découvrez comment configurer Grafana Alloy pour superviser le serveur sur lequel il s'exécute, av...

Grafana Alloy vs Grafana Agent vs Promtail : Lequel choisir ?

Découvrez l'évolution des collecteurs de télémétrie de l'écosystème Grafana. Comparatif détaillé ...

Grafana Alloy: Metrics Collection (Prometheus & Ecosystem)

Learn how to configure Grafana Alloy to collect, transform, and forward metrics using the Prometh...

Support us

♥ SUPPORT US

Support RousselTM Learning

Courses, articles, labs and certificates stay free with no intrusive ads. A voluntary contribution, of any amount you choose, pays for hosting, lab environments and new content.

Contribute with PayPal Any amount · card or PayPal accountLearn more
QR code PayPal
Or scan this QR code with your phone

Thank you, every contribution counts!