Logs from different services have mismatched timestamps and some appear "in the future". How do you fix it?

IntermediateScenarioLogging Pipelines
Answer

Situation read → Mix of local time zones, missing time zones in log formats, clock drift, or the shipper using ingest time.

What I'd do →

  1. Standardise on UTC with RFC 3339 timestamps (2026-03-02T10:15:01.123Z) in all apps.
  2. Parse the app timestamp in the shipper (Alloy stage.timestamp, Fluent Bit parser Time_Key/Time_Format).
  3. Ensure NTP/chrony is running and alert on node_timex_offset_seconds above 50 ms.
  4. Check Loki's reject_old_samples_max_age and creation_grace_period for rejected entries.

Why → Correlation across services is only as good as clock and format consistency.

Interview tip → Clock drift silently breaks trace and log correlation; monitor it.

All Monitoring & Observability questions Roadmap: Logging & tracing

More on Logging Pipelines