Skip to main content

πŸ” Loki How-To Guides

Ready to hunt down some bugs? This guide shows you how to search and analyze logs effortlessly within our environment.

(For advanced LogQL tricks, check out the official Grafana Loki documentation.)

πŸ“Š Querying Logs in Grafana​

Loki is a backend powerhouse, so it does not have its own UI. Instead, we use Grafana as our magnifying glass!

  1. Open Grafana and click the Explore tab (the compass icon on the left). 🧭
  2. Select Loki from the data source dropdown at the top left.
  3. Use the Label filters to instantly narrow down your hunt (e.g., set app = my-backend-service or namespace = production).
  4. Smash that Run query button to stream your logs! πŸš€

πŸͺ„ Jumping from Traces to Logs (Magic!)​

Here is the absolute coolest feature of our stack: seamless integration between Tempo (traces) and Loki (logs). ✨

Are you staring at a slow or failed request trace in Tempo?

  1. Look closely for a tiny document icon right next to the failing span.
  2. Click it!
  3. Grafana will instantly split the screen and query Loki for the exact logs generated by that specific service during the exact microsecond of that trace!

It is the ultimate debugging shortcut! 🎯