Skip to content
Tutorials Center
My learning

Topics

Lesson 25 of 37 ยท Dashboards and Reporting

SLA and Availability Reports

Define services, SLIs and SLOs in Zabbix, calculate availability and downtime budgets, configure SLA reports and scheduled PDF reports, and compare with Nagios reports.

"Was the shop up last month?" sounds like a simple question, but the answer depends on definitions: up for whom, measured how, excluding what? Zabbix has a Services feature and SLA reports to answer it consistently. This lesson explains the terms, the Zabbix objects, and the arithmetic of availability, with Python stand-ins to practice the numbers. The product is not runnable here, so interface steps are described in words.

Terms you must keep apart

  • SLI (service level indicator): the measured quantity, for example "percentage of minutes in which the checkout page returned HTTP 200".
  • SLO (service level objective): your internal target, for example 99.9 percent.
  • SLA (service level agreement): the promise to customers, often with a penalty. An SLA should be looser than the SLO so you have a margin.
  • Error budget: the downtime your SLO allows over a period.

Availability for a month of 30 days:

Target Allowed downtime per 30 days
99% about 7.2 hours
99.9% about 43 minutes
99.95% about 21.6 minutes
99.99% about 4.3 minutes

Services in Zabbix

Under Services > Services you build a tree. A service has a name, a status calculation rule, and optionally problem tags that connect it to real problems. Typical tree:

TEXT
Online shop
  Web frontend      (problem tags: service=web)
  Database          (problem tags: service=db)
  Payment gateway   (problem tags: service=payment)

The parent's status is calculated from children by a rule you choose: "most critical of child services", "status is problem if at least N children are in problem", "set status to OK" (display only), and so on. Child services can have weights and the rule "Status is problem if N or more children have a problem" or "if at least N% of children". Tags on triggers (such as service:web) make the service go into problem when a matching problem exists with enough severity.

There is also a root cause concept: service problems show which problems caused the state, so people look at the reason rather than at the symptom.

SLA definitions and reports

An SLA object (Services > SLA) contains:

  • A name and SLO percentage, for example 99.9.
  • A reporting period: daily, weekly, monthly, quarterly or annually.
  • A schedule: 24x7 or business hours, per weekday.
  • Optional excluded downtimes: planned maintenance windows that do not count.
  • A service tag filter: the SLA applies to all services with the tag sla:gold, for instance.

The SLA report (Services > SLA report) then shows for each period and each service the SLI, the uptime, downtime and error budget left, and whether the SLO was met. The dashboard widget "SLA report" shows the same on a wall.

Two details deserve attention:

  1. Service status drives downtime. If your service tree turns "problem" for a trivial warning, your SLA looks bad. Use severity thresholds in the problem tags.
  2. Excluded downtime is declared in the SLA object, so an unannounced outage cannot be hidden later. Maintenance periods that are configured on hosts affect problem creation but should be planned consistently with the SLA exclusions.

Scheduled and ad-hoc reports

Zabbix can also create scheduled reports (Reports > Scheduled reports): a dashboard rendered to a PDF and sent by email on a schedule (daily, weekly, monthly), with a subject and message. It needs the zabbix-web-service component and a configured URL for it. This is the usual way to send a "Monday morning" summary to management.

Other reports under Reports: System information, Availability report (per trigger), Top 100 triggers, Audit log, Action log and Notifications. In the availability report, the time a trigger spent in OK versus PROBLEM is shown per host.

Nagios reports

Nagios Core provides an Availability report (CGI avail.cgi) with uptime per host and service, a Trends view and an Alert histogram. They read from the status log and archived logs. Add-ons (Nagios XI, Thruk, Check_MK) provide SLA reports with schedules and PDFs. If you rely on Nagios alone, the report is limited to what the logs hold, and you must decide how to treat scheduled downtime (SCHEDULED DOWNTIME entries are counted separately).

Stand-in: downtime budget

Python Error budget calculator (Python stand-in)

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

Stand-in: SLI from outage windows

This computes availability from outage intervals while excluding a maintenance window, similar to what an SLA report with excluded downtime does.

Python Availability with excluded downtime (Python stand-in)

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

Practical advice

  • Decide what "down" means before you configure anything: one failed probe, or a trend over several minutes?
  • Prefer synthetic checks (web scenarios from outside) for customer-facing SLIs; an agent on the server only proves the server thinks it is fine.
  • Review problem tags quarterly. Services without tags never show problems.
  • Keep SLOs stricter than SLAs.

Check your understanding

Quick check ยท 5 questions

of 5 answered You scored / 5 ยท perfect!

  1. 1. Roughly how much downtime does 99.9% allow in a 30-day month?

    30 days is 43,200 minutes; 0.1 percent of that is 43.2 minutes.
  2. 2. What is the difference between an SLO and an SLA?

    Keep the SLO stricter than the SLA to leave a safety margin.
  3. 3. How does a Zabbix service learn about problems?

    Services have problem tags that match tags on problems.
  4. 4. What is needed to send scheduled PDF reports?

    Scheduled reports render dashboards through the web service.
  5. 5. Which exclusion belongs in the SLA object?

    Only agreed, planned downtime should be excluded.

Summary

  • SLI is measured, SLO is a target, SLA is a promise; the error budget is the downtime you can afford.
  • Zabbix Services form a tree with status rules and problem tags; SLA objects add schedule, SLO and exclusions.
  • Scheduled reports send dashboards as PDF through the web service.
  • Nagios reports availability from logs; richer SLA reporting needs add-ons.

Next: Zabbix Architecture and Sizing