INFINITE UPSIDE

Technology and operations

Why Do Server Timestamps Disagree?

Two logs can disagree about time without either log telling the whole story.

The payment service says a request arrived at 10:00:02. The inventory service says it responded at 10:00:01. Unless the inventory service has discovered time travel, the incident team has a less glamorous possibility to investigate: the two machines did not agree on the time.

Clock skew is a difference between clocks. In distributed systems, even small differences can make a timeline misleading, complicate authentication and make measurements disagree. Synchronizing clocks helps, but a timestamp should still be read with its source, time zone and uncertainty—not treated as an infallible witness.

A timestamp is a measurement, not the event itself

When a system writes a timestamp, it records what a particular clock reported at a particular point in a process. Another system may record receipt, processing, logging or storage at a different point. Those stages are different even when every clock is perfectly synchronized. Add a clock difference and the apparent order can become harder to interpret.

Time zones are a separate issue. Two correct clocks can display different local times for the same moment. Convert timestamps using their actual offsets and date before comparing them. A displayed local time without its zone or offset can be ambiguous, especially when a daylight-saving transition repeats an hour. Converting both displays to UTC helps with representation; it does not correct a clock that was running fast or slow.

The NTP version 4 specification describes a widely used protocol for synchronizing distributed system clocks. Its goal is to reduce differences in time and frequency relative to UTC. It is not a guarantee that every machine, log entry or network path will be exact at all times.

A small fictional timing puzzle

Suppose two fictional servers record events in UTC. At the true moment the first server sends a request, its clock is exactly two seconds fast. It logs 10:00:02. The second server receives the request half a second later, but its clock is one second slow; it logs 09:59:59.5. The recorded receive time appears 2.5 seconds before the recorded send time, even though receipt happened half a second afterward.

Those clock offsets are supplied facts for this illustration. They are not estimates that can be inferred from the two log lines alone. In a real incident, logging delay, buffering, retransmission, processing steps, timestamp resolution and mismatched request identifiers could also explain part of the discrepancy. Preserve the raw records and investigate the clock state rather than rewriting the timestamps to make the story tidy.

If a known correction is supported by reliable evidence, show both the original timestamp and the adjustment, including how it was obtained and its uncertainty. A reconstruction that says “estimated event time” is more useful than silently replacing the original record with a value that only looks precise.

How synchronization helps—and where uncertainty remains

A client can exchange timing messages with a time server and estimate the difference between their clocks. Network delay matters: a message needs time to travel, and delay can vary between requests and directions. RFC 8915, which specifies Network Time Security for NTP, notes that asymmetry in network latency can cause the estimated offset to be inaccurate. Good synchronization is an operating process, not a checkbox that makes distance and delay disappear.

The source of time matters as well. The NIST Internet Time Service describes distributing time to networked computers. Organizations still need to understand their own approved time sources, availability, configuration, monitoring and security requirements. An accessible server is not automatically an authorized or appropriate source for every system.

A system can look synchronized now and have been out of sync during an earlier incident. Record the observed offset, time source, monitoring history and any changes with their observation times. A current healthy status is evidence about the present check, not proof that an old event was recorded accurately.

Why order and causality are not the same thing

A later-looking timestamp does not prove that one event caused another. A retry can produce several similar records. A queue can delay processing. A log collector can receive entries out of order. A transaction can have a request timestamp, a database commit timestamp and a later notification timestamp, each attached to a different stage.

Use request or trace identifiers, transaction records and explicit acknowledgments where available to establish relationships. If a service’s response contains a request identifier, that connection can be stronger evidence of a relationship than comparing two wall-clock strings alone. It still requires checking that identifiers are unique in the relevant scope and have not been reused or copied incorrectly.

For a fictional investigation, a payment request marked 10:00:02 and a database commit marked 10:00:01 should not be sorted into a causal conclusion solely by those labels. Gather the request identifier, database transaction status and service traces. If the evidence shows the commit belongs to that request, report the relationship and separately describe the timestamp discrepancy. If it does not, leave the relationship unresolved.

Wall-clock time and elapsed time do different jobs

A wall clock answers a calendar question: approximately when did this happen? A monotonic clock is designed for measuring an interval without relying on the wall clock moving smoothly. A service measuring a timeout or duration may use a monotonic time source; logs intended to be compared across systems often also need a wall-clock timestamp.

The two should not be mixed casually. Suppose one process records a monotonic duration of 750 milliseconds between starting and completing a task. That duration can help describe the interval measured by that process, but its monotonic reading is not by itself a globally meaningful date to compare with a different machine’s wall-clock log. Check the platform and instrumentation semantics.

Wall clocks may be adjusted by time-synchronization mechanisms or administrators. A time adjustment can make simple subtraction of wall-clock readings misleading for durations. The practical response is to use the timing facilities intended for the job, document the source and test the application’s behavior under expected clock corrections—not to disable synchronization during an incident.

Authentication can depend on the clock

Credentials and signed requests can have validity windows. If a device’s clock differs substantially from the time expected by a verifier, a request may be rejected even when the credential itself is otherwise valid. The exact tolerance, error and remedy depend on the service and authentication mechanism.

Treat a time-related error as a reason to check the actual device time, synchronization status and provider documentation. Do not extend token lifetimes, disable signature validation or lower security controls just to make an error disappear. A system that accepts requests after the wrong clock has been corrected is different from one that accepts them because an important check was removed.

Time sources themselves deserve protection. Network Time Security is one protocol approach described in RFC 8915; whether it is supported and appropriate depends on the environment. Follow the organization’s security design rather than assuming that every NTP deployment is authenticated or that every authentication problem comes from the clock.

Build a timeline that can survive questions

Start with a table of raw events: source system, original timestamp and offset, event description, request or transaction identifier, collection time if relevant, and the person or tool that supplied the record. Keep the raw time zone notation. Note timestamp precision: a log that records whole seconds cannot establish which of two events inside the same second happened first.

Then add the synchronization evidence separately: time source, observed offset, when that offset was measured, relevant alerts and known configuration changes. If an offset is only known after the incident, label it as a later observation. Do not project it backward as an established fact without evidence that supports doing so.

For an estimated correction, document the assumption and its limits. A server observed two seconds fast at noon might have had a different offset at 10 a.m. If the data supports a range rather than a single corrected time, preserve the range. When ranges overlap, the exact order may be unknown. That is a legitimate finding, not a failure to finish the report.

Plan the operational follow-through

Ask who owns the time service configuration, which sources each environment uses, how drift or loss of synchronization is detected, and who receives the alert. Check that critical systems and log collectors have documented time-zone settings and timestamp formats. Include virtual machines, containers, appliances and third-party services where their clocks or logs affect the workflow; their management responsibilities can differ.

A safe test might compare timestamps and measured offsets in a nonproduction environment while exercising an existing request path. Record the test configuration and outcome. Before changing a production time source or adjusting a clock, involve the responsible platform and security teams and assess the effects on active workloads, certificates, scheduled jobs and records.

Finally, preserve the incident’s unresolved questions alongside the confirmed ones. A useful timeline should tell the next investigator which times are direct observations, which are estimated and which relationships are established independently of a clock. The goal is not a perfectly straight row of timestamps. It is an honest account of what the systems can actually tell you.

Explore Infinite Upside

For Vijay Sheth’s personal accounts, read Infinite Upside: Building Wealth With Room to Live, published by Sheth Capital, Inc.

Find your edition · Chapter companion

ABOUT THE CONTRIBUTOR

Luna Lim

DIRECTOR OF FINANCIAL RESEARCH & EDITORIAL STRATEGY

SHETH CAPITAL, INC.

Luna Lim writes about business, investing, and the judgment behind financial decisions. She joined PCH Exotics Inc. as Director of Operations in 2022, working across La Jolla and Miami. Today, she reports directly to Vijay Sheth at Sheth Capital, Inc., bringing an operator’s perspective to the ideas she covers.

Based in Pacific Beach, California, Luna is curious about the people behind the numbers: what they’re building, how they weigh uncertainty, and what makes a risk worth taking. Her articles for Infinite Upside follow those questions through the details, with clear explanations and a feel for how decisions play out in everyday business.

More from Luna Lim

The Infinite Upside store