Loki

  • By Canonical Observability
Channel Revision Published Runs on
latest/stable 151 01 Aug 2024
Ubuntu 20.04
latest/candidate 160 01 Aug 2024
Ubuntu 20.04
latest/beta 161 01 Aug 2024
Ubuntu 20.04
latest/edge 163 09 Aug 2024
Ubuntu 20.04
1.0/stable 104 12 Dec 2023
Ubuntu 20.04
1.0/candidate 104 22 Nov 2023
Ubuntu 20.04
1.0/beta 104 22 Nov 2023
Ubuntu 20.04
1.0/edge 104 22 Nov 2023
Ubuntu 20.04
juju deploy loki-k8s --channel 1.0/stable
Show information

Platform:

Logs take up quite a bit of storage, and querying them can be cpu-intensive. Node sizing depends on:

  • Logging rate
  • Desired buffer for spikes in logging rate
  • Desired retention period

With such information at hand, you can refer to the performance envelope for sizing guidelines.

How to measure a workload’s logging rate

The loki distriburor already exports the metrics we need to determine logging rate. Deploy your solution, and relate workload under test to loki, for example:

Be sure to relate to loki only the workload(s) you’re measuring the rate for.

Usually a 48hr view of the following expressions should give a good idea about logging rate:

  • GB/day: sum(rate(loki_distributor_bytes_received_total[5m]) / 1e9 * 60*60*24)
  • Lines/min: sum(rate(loki_distributor_lines_received_total[5m]) * 60)