Back to sections

Monitoring & Observability Interview Questions & Answers

A sample of real Monitoring & Observability interview questions with full answers and explanations - practice for interviews or certification exams.

easy

1. An application exposes two separate HTTP health check endpoints: one that tells the platform 'restart me if this fails' and another that tells it 'don't send me traffic yet, but no need to restart me.' What are these two checks called?

Liveness probe and readiness probeCorrect
Black-box check and white-box check
Synthetic check and heartbeat check
Uptime check and smoke test

A liveness probe answers 'is this process stuck or deadlocked?', and failing it typically triggers a restart. A readiness probe answers 'can this instance currently serve traffic?', such as during startup while it's still warming a cache or waiting on a dependency, and failing it just removes the instance from load balancing without restarting it. Conflating the two is a common mistake that causes unnecessary restarts of instances that just need more time to warm up.

medium

2. A monitoring team keeps every raw, 15-second-resolution metric sample forever, and their storage costs have grown enormous even though nobody ever looks at 15-second-resolution data from two years ago. What's the standard practice to control this cost without losing all historical visibility?

Switch from a pull-based to a push-based monitoring model
Store all metrics as summaries instead of counters
Delete all data older than a week, since historical trends aren't useful
Downsampling: reduce the resolution of older data (for example, keeping only hourly averages after 30 days) while keeping full resolution for recent data, balancing storage cost against retained detailCorrect

Downsampling reduces the granularity of data as it ages, aggregating raw high-resolution samples into coarser buckets (like hourly or daily rollups) for anything beyond a certain age, since long-term trend analysis rarely needs second-by-second precision. This keeps storage costs bounded while still preserving the ability to look at capacity trends or year-over-year comparisons, unlike simply deleting old data outright.

hard

3. A checkout request takes 2 seconds end-to-end. Its distributed trace shows: API gateway span 50ms, auth-service span 40ms, inventory-service span 1800ms (itself containing a 1750ms child span for a single database query), payment-service span 90ms. Where should you focus optimization effort?

The API gateway, since it's the entry point for the whole request
You can't tell from a trace alone; you'd need to add more logging first
The auth-service, since authentication runs on every single request
The database query inside inventory-service's span, since it accounts for the vast majority of the total request durationCorrect

A trace's spans form a waterfall showing exactly how much of the total duration each hop and sub-operation consumed, and here the child span for one database query, 1750ms, is nearly the entire 2-second budget, making it the obvious bottleneck. The gateway, auth, and payment spans are all fast and irrelevant to this particular slowdown, so optimizing them wouldn't move the needle. This is exactly what makes tracing more useful than logs or metrics alone for this kind of question: it directly attributes where time went within one request, with no extra instrumentation needed beyond the spans already captured.

easy

4. A page fires for 'disk usage above 90% on db-primary.' Attached to the alert is a link to a document with step-by-step instructions for how to safely free up space on that specific server. What is this document called?

A service level agreement
A changelog
A runbookCorrect
A postmortem

A runbook is a step-by-step reference tied to a specific alert or failure mode, written so that whoever is on call, even someone unfamiliar with that particular system, can follow a known-good procedure instead of improvising under pressure. Linking a runbook directly from the alert reduces both mean time to resolution and the cognitive load on the responder.

medium

5. A service's request-counter metric resets to zero every time its pod restarts (a routine deploy or crash). An engineer is worried this will cause their PromQL rate() graph to show a nonsensical giant negative spike or drop to zero every time a restart happens. Should they be worried?

No, rate() (and irate()) are specifically designed to detect counter resets and correctly handle them, so a restart doesn't produce a false negative spikeCorrect
No, because counters never actually reset, only gauges do
Yes, this is why counters should never be used for anything that might restart
Yes, they need to manually add offset logic to their query to compensate for every possible restart

Prometheus's rate() function is reset-aware: when it sees the current value drop below the previous one, it assumes a counter reset occurred (rather than a real negative rate, which is impossible for a counter) and adjusts the calculation accordingly instead of producing a nonsensical negative spike. This is precisely why counters, paired with rate(), remain the standard way to track cumulative totals like request counts even across restarts.

hard

6. A database's disk usage has been growing at a steady, predictable 2% per week for the past six months, with no signs of slowing. The team has no alert on this at all, only reacting once disk usage crosses 95% and writes start failing. What practice should they adopt instead?

Capacity planning: use the historical trend to project forward and forecast when the disk will hit critical levels, so the team can provision more storage (or address the growth) well before it becomes an emergencyCorrect
Wait for the 95% alert to fire, since that's the only moment action is actually needed
Increase the alert threshold to 99% so there's more headroom
Switch the disk usage metric from a gauge to a counter

Capacity planning uses historical trend data to forecast when a resource will run out under current growth rates, turning what would otherwise be a reactive, middle-of-the-night emergency into a scheduled, proactive piece of work with weeks of lead time. A single threshold alert at 95% only tells you the problem is imminent, whereas trend-based forecasting tells you it's coming weeks in advance, while there's still time to provision more capacity calmly.

easy

7. A team sets up an automated script that runs every minute from an external location, logging into their website and clicking through a real checkout flow to confirm the whole thing still works, independent of any internal metrics. What is this technique called?

Canary deployment
Log aggregation
Distributed tracing
Synthetic monitoringCorrect

Synthetic monitoring proactively simulates real user behavior from the outside on a schedule, so problems can be caught even when there's no real user traffic hitting the affected path at that moment. It's a form of black-box monitoring, since it checks observable outcomes without looking at the system's internals, which is exactly what makes it good at catching issues that internal metrics might miss.

medium

8. An engineer adds a `user_id` label to a request-counter metric so they can debug individual users' traffic. Within a day, the metrics backend runs out of memory and dashboards stop loading. What happened?

The metrics backend hit its limit on the number of distinct metric NAMES, not label values
The metric type should have been a gauge instead of a counter
The user_id label caused a cardinality explosion: each unique value creates a brand-new time series, and with millions of users that's millions of seriesCorrect
Adding any label to a counter metric doubles its memory usage by design

Every unique combination of label values creates a separate time series in the underlying store, so a label like user_id with millions of possible values (high CARDINALITY) can multiply one metric into millions of series almost overnight, which is exactly what overwhelms storage and indexing. This is a cardinality problem, not a metric-type problem, switching to a gauge wouldn't fix it, and the limit that gets hit is on total time series or label combinations, not on the count of distinct metric names. The standard fix is to keep high-cardinality fields like user_id in logs or traces, where they belong, not as a metric label.

hard

9. A platform team supports 40 microservices and wants a single Grafana dashboard template that any engineer can use to view latency for whichever specific service they're currently investigating, without the team having to hand-build and maintain 40 nearly-identical dashboards. What Grafana feature is designed for exactly this?

Alert silences
Annotations
Dashboard variables (template variables), which let a dropdown at the top of the dashboard swap out which service's data every panel queries, using one shared dashboard definitionCorrect
Downsampling rules

Dashboard variables let a single dashboard definition stay generic, with panel queries referencing a variable like $service instead of a hardcoded service name, and a dropdown at the top lets whoever's viewing it pick which specific value to plug in. This turns what would otherwise require 40 separate, hand-maintained dashboards into one reusable template, which is exactly the maintenance burden the scenario describes.

easy

10. Which of the three pillars of observability, metrics, logs, and traces, is best suited for answering 'how did this single request travel across our five microservices, and where did it spend most of its time?'

Logs, because they record every discrete event with full context
Metrics, because they capture numeric time-series data like request counts and latency histograms
Traces, because they follow the path of a single request as it moves across services and show how long each hop tookCorrect
Alerts, because they notify you the moment latency crosses a threshold

Traces stitch together spans from every service a single request touched, showing the request's path and per-hop timing, exactly what's needed to find where time was spent for one request. Metrics are great for aggregate trends and dashboards but discard per-request identity, and logs give rich detail per event without inherently linking events across services into one request's journey. Alerts aren't a pillar of observability at all, they're a downstream consumer of metrics, logs, or traces.

Want to practice under real conditions?

Try the full timed Monitoring & Observability quiz.

    Welcome to OpsQuiz!

    Real scenario-based DevOps questions, hands-on practice, and clear explanations for every answer.