Payments are experiencing issues due to temporary restrictions in Russia. If your payment does not go through, please submit a support request.Our support team is available 24/7 — we are always here to help with hosting and server issues.We are now accepting requests for dedicated server rental and colocation services in our data center.Reminder: we recommend enabling backups for additional data protection.A new VPS/VDS lineup with NVMe storage and improved performance is now available.Maintenance work on some servers has been completed. All services are operating normally.
Article3 min readViews1

Incorrect Server Time: Checking Clocks and Synchronization

How to use timedatectl to distinguish between a time zone error and clock desynchronization, and gather data before manually adjusting the time.

Clocks in a room with server equipment
In this article

Certificate errors, unexpected token expiration times, and strange log entry orders are sometimes related to time. However, a display discrepancy does not always mean the clock is running incorrectly. The server may store the correct time but display it in a different time zone.

Check the clock status

On Linux with systemd, run:

timedatectl status

Compare local time, UTC, time zone, and synchronization details. Do not draw conclusions solely based on whether the server clock matches the clock on your work laptop. First, convert both timestamps to the same time zone.

For a compact output of selected properties:

timedatectl show -p Timezone -p NTP -p NTPSynchronized

Having an active synchronization mechanism and having confirmed synchronization are different things. A service may be running but still fail to receive a valid response or lack access to the time source.

Identify which service is synchronizing the time

If systemd-timesyncd is in use, an additional command is available:

timedatectl timesync-status

This command applies specifically to this mechanism. On a server with a different time client, the result may be unavailable or inapplicable. Do not install a second client alongside a running one just to generate the desired output.

Record the time server in use and the connection status. In virtualized environments, also consider guest system and platform settings: clock behavior is determined by more than a single parameter within the application.

Correlate the time with the error

Example: an application log records UTC time, while the monitoring dashboard displays local time. Events appear spread across several hours, even though they refer to the same moment. The fix lies in interpreting the report, not in adjusting the system clocks.

Another scenario: the clocks are indeed drifting from a trusted source, and expiration errors occur simultaneously. In this case, verify the availability of time sources and the synchronization service logs. A single certificate error does not prove desynchronization: the certificate may be invalid, or the chain may be incomplete.

Why You Should Not Manually Set the Clock Immediately

A sudden time shift affects applications, schedules, and log interpretation. It can complicate the analysis of an incident that has already occurred. Before making changes, you must understand the cause and the correction method selected for this system.

If the service processes payments or scheduled jobs, coordinate the fix with its owner. Do not mix a time zone change with an absolute time correction: these are different operations with different consequences for display and schedules.

How to Verify the Result

After fixing the synchronization mechanism, capture the state again and test the problematic application scenario. In the report, specify exactly what was incorrect: the time zone, absolute time, synchronization source, or log interpretation.

Save the original discrepancy and the recovery moment. This will help correctly read records created before the fix and avoid searching for a repeated error where only the display has changed. A reliable result is consistent clock synchronization and a clear timeline, not a single manually set correct moment.

Discussion 0

Share your experience and ask questions. Comments without links appear after editorial review.

No comments yet. Start the discussion.