Monitoring 101: Metrics, Logs, and Traces

The three pillars of observability explained plainly — what metrics, logs, and traces each tell you, and which one to reach for first depending on the question you're actually asking.

Free preview · 1 of 3 free left
Topic: Operations Guide beginner 9 min read

Why this matters

New engineers often reach for logs first, every time, because it's the most familiar tool — but logs are the slowest way to answer many operational questions. Knowing which of the three tools actually answers your specific question saves real time during an incident, not just in theory.

What you'll learn

What each of the three observability pillars is actually good for, a simple rule for choosing which one to check first, and why they work best used together rather than any one alone.

Metrics — good for "is something wrong, and since when"

A metric is a number tracked over time: CPU percentage, request count per minute, average response time, queue depth. Metrics are cheap to collect at high frequency and excellent for two things: alerting (a threshold crossed) and spotting trends (did this start gradually or suddenly, and exactly when). What metrics can't tell you is why — a CPU spike tells you something is consuming CPU, not which specific request or code path caused it.

Logs — good for "what exactly happened, in detail"

A log is a discrete, timestamped record of a specific event, usually with rich context (an error message, a stack trace, a request's parameters). Logs are the right tool once you already know roughly when something went wrong (from a metric or an alert) and need to know what — but searching raw logs with no starting time window at all, across a busy production system, is slow and often the wrong first move.

Traces — good for "where in a multi-step request did the time go"

A trace follows one specific request across every service, function, or system it touched, recording how long each step took. Traces are the right tool specifically for distributed, multi-step problems: "the page is slow, but is it the database, an external API call, or the application's own processing?" A trace answers that directly; metrics and logs alone usually require more inference to get there.

A simple rule for which to check first

  1. See a metric alert or a dashboard anomaly? → Check metrics first, to confirm the actual scope and timing.
  2. Know the rough time window, need the specific cause? → Check logs for that window.
  3. Know it's slow, but not which step is the bottleneck? → Check traces (if available) to isolate the slow step, then logs for that specific step.

Used in this order, the three tools narrow the investigation at each stage rather than requiring you to read everything.

What's next

Metrics are usually the entry point into an investigation; once you have a time window, the discipline of reading logs efficiently (rather than scrolling endlessly) is covered in Reading Logs Backwards: A Debugging Habit. For a structured way to turn "I found the cause" into "I found the root cause," see Root Cause Analysis: A Simple Framework.

Part of: Support Engineers, System Administrators, DevOps Beginners, Cloud Beginners

← Back to Guides

Next → Portfolio Projects That Actually Impress What makes a student portfolio project actually stand out to recruiters — depth over quantity, finishing over starting, and how to present projects so their value is obvious.