InterviewStack.io LogoInterviewStack.io

Logging, Tracing, and Debugging Questions

Covers design and implementation of observability and diagnostic tooling used to troubleshoot applications and distributed systems. Topics include structured, machine-readable logging, log enrichment with context and correlation identifiers, log aggregation and indexing, retention and cost trade-offs, and searchable queryability. It also includes distributed tracing to follow request flows across services, trace sampling and propagation, and correlating traces with logs and metrics. For debugging, covers production-safe debugging techniques, live inspection tools, core dump and profiling strategies, and developer workflows for reproducing and isolating issues. Also covers turning diagnostic signal into dashboards and alerts (for example in tools like Grafana or Datadog), integrating diagnostic output into monitoring and CI pipelines, and producing clear diagnostic reports for incident response and postmortems. Emphasizes tool selection, integration patterns, privacy and security considerations for logs and traces, and practices that make telemetry actionable for root-cause analysis.

EasyTechnical
64 practiced
Explain the differences between logs, metrics, and traces as observability signals. For each type describe typical use-cases, aggregation and retention properties, cardinality concerns, and example tools. Finally, give one concrete debugging scenario where logs are superior and one where traces are superior.
MediumTechnical
56 practiced
Compare Elasticsearch+Kibana, Grafana Loki, Splunk, and BigQuery as logging backends. For each option describe expected scale, query latency characteristics, cost model (indexing vs storage vs query), strengths and weaknesses, and ideal use-cases for an SRE team.
MediumTechnical
104 practiced
Implement a Python generator function stream_json_events(stream) that reads a potentially infinite byte stream containing newline-delimited JSON and yields parsed dicts. Requirements: handle partial chunks where JSON objects can be split across read() calls, protect against insanely long lines by rejecting lines >1MB, and operate with bounded memory (do not buffer the entire stream). Provide a code sketch and explain memory characteristics.
HardSystem Design
71 practiced
Design a long-term archival strategy for terabytes of logs per day. Compare cold object storage (S3/Glacier) with columnar formats (Parquet) and storing only aggregates in a data warehouse. Discuss retrieval patterns, costs, query performance for forensic use, and a migration plan that supports both occasional fast restores and batch analytics.
HardSystem Design
57 practiced
Architect an end-to-end observability platform for a company producing 10 million log events per second, requiring 90-day searchable hot retention for critical services and economical longer-term archival. Provide high-level choices for ingestion, buffering, stream processing, indexing, storage tiers, query engines, cost optimizations (compression, downsampling), SLA targets for query latency, and approaches to HA and upgradeability.

Unlock Full Question Bank

Get access to hundreds of Logging, Tracing, and Debugging interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.