Do these 3 things before closing this tab:
1Repair Windows errors before they cause bigger problems2Scan for outdated or missing drivers - takes under a minute3Clear out junk files and repair common Windows errorsA one-second reversal in a Linux timestamp is usually not damaged data: it is a consequence of using the civil-time clock for a job that requires an elapsed-time clock, or of applying leap-second and NTP corrections through competing time services. Fix it in two places: use CLOCK_MONOTONIC (or, for specialized cases, CLOCK_MONOTONIC_RAW) for durations, deadlines and event ordering; then ensure exactly one time synchronizer controls CLOCK_REALTIME and that chrony’s leap policy matches your upstream NTP service.
Keep CLOCK_REALTIME for user-visible UTC timestamps, expiry dates and audit records. It represents civil time and can step. If an application needs a continuous atomic-time scale, use CLOCK_TAI and document its semantics.
As an Amazon Associate I earn from qualifying purchases.
Why a Linux timestamp can move backward
Linux exposes several clocks with different guarantees. CLOCK_REALTIME is the system wall clock: the value used for ordinary UTC dates, file timestamps and logs. It is corrected by NTP and can also be adjusted by an administrator or service. It is therefore not a duration timer.
The Tool Desk
Outbyte PC Repair FREEClear out junk files and repair common Windows errorsFree Scan →Outbyte Driver Updater FREEScan for outdated or missing drivers - takes under a minuteDriver Scan →The kernel documentation explicitly warns that the realtime clock “can jump backwards due to a leap second update, NTP adjustment settimeofday() operation from user space.” A leap-second insertion is handled by repeating one second of civil time. Chrony documents the Linux sequence this way: “When inserting a leap second, the kernel steps the system clock backwards by one second when the clock gets to 00:00:00 UTC.” A deletion steps the clock forward at 23:59:59 UTC.
#1 Best Overall
- [Ultra-Lightweight Ear Buds Designed for Small Ears] Each earbud weighs only 3.7g and features a compact, ergonomic in-ear design made especially for small ears. Secure, low-profile, and comfortable for workouts, all-day wear or overnight sleeping.The ultra-slim profile sits flush in your ear with no hard edges poking or rubbing, so you can even sleep on your side without discomfort.
- [Immersive Stereo Sound with TOZO OrigX Technology] TOZO OrigX tuning delivers clear vocals, balanced mids, and natural stereo sound for music, podcasts, and videos.
- [Long Battery Life for Daily Use] Get up to 7 hours of playtime on a single charge, with up to 32 hours total using the charging case—ideal for workdays, commuting, and extended listening sessions.
- [Bluetooth 5.3 & Stable Connection] Bluetooth 5.3 provides fast pairing, stable wireless performance, and reduced dropouts as you move around home or office.
- [Deep Bass with Clear Vocals] High-performance drivers produce punchy bass while keeping vocals clean and detailed for everyday listening.
The clock_settime(2) manual also says that CLOCK_REALTIME ignores leap seconds. That means its numeric values are not a leap-aware, strictly increasing timeline. During correction, two events can receive the same civil-time value, or a later reading can be numerically smaller than an earlier one. This is expected behavior for wall time, not evidence that the hardware clock or filesystem has necessarily lost a second.
A second cause is ordinary synchronization. If the host clock is off by a second, an NTP daemon may step it, independent of a scheduled leap. Running two daemons at once makes this worse: each can apply a different correction or leap policy.
Choose the right clock for each job
| Clock | Meaning | Can step or repeat? | Best uses | Important limitation |
|---|---|---|---|---|
CLOCK_REALTIME |
Adjustable civil/wall time | Yes; NTP, manual changes and leap handling can alter it | User-visible UTC, expiry dates, audit records and timestamps that must survive reboot | Never assume readings strictly increase or use subtraction for elapsed time |
CLOCK_MONOTONIC |
Monotonic time since an unspecified starting point | Does not jump backward when wall time is corrected | Timeouts, retry intervals, latency, scheduling deadlines and event ordering | Not a calendar timestamp and should not be persisted as a date |
CLOCK_MONOTONIC_RAW |
Monotonic hardware-based clock without NTP frequency adjustments | Does not follow wall-clock steps | Measurements where the raw hardware rate is preferable | Its rate is not disciplined by NTP, so long measurements can drift from UTC |
CLOCK_TAI |
Continuous atomic-time reference with TAI-UTC offset semantics | Designed to avoid leap-second jumps | Applications that need an atomic, continuous timescale | It is not ordinary UTC; all consumers must understand the offset and representation |
Use monotonic deadlines, not repeated realtime samples
For a timeout, read CLOCK_MONOTONIC once, add the allowed interval, and compare subsequent monotonic readings with that deadline. Do not compute a deadline from CLOCK_REALTIME and repeatedly subtract the current wall clock: a backward step can make a timeout appear longer, while a forward step can make it expire immediately.
In C, the basic pattern is:
#include <time.h>
static long long monotonic_ns(void) {
struct timespec ts;
clock_gettime(CLOCK_MONOTONIC, &ts);
return (long long)ts.tv_sec * 1000000000LL + ts.tv_nsec;
}
long long deadline = monotonic_ns() + 5LL * 1000000000LL;
while (monotonic_ns() < deadline) {
/* wait for work, using a monotonic-aware API where available */
}
Use CLOCK_MONOTONIC_RAW only when excluding NTP frequency adjustments is intentional. For most application timeouts and ordering, CLOCK_MONOTONIC is the appropriate default.
Rank #2
- 【IP68 Waterproof Multifunctinal Smart Watch】Torjalph fitness activity tracker smart watch is IP68 waterproof technology ,you can wear it when swimming,handwashing,it's rain-proof which means that you perform multiple exercise modes outside without worrying about sweat or rain corroding your fitness smart watch,and this watch equipped with a 230 mAh large capacity battery magnetic charging ,and this sports activity tracker watch can be used 5-7 days If fully charged.
- 【Larger 1.83'' Full Screen Watch & Multi-dial Selection】1.83 inch full HD color touch screen smart watch for men / women provides excellent 240*284 resolution image quality ,This Bluetooth smart watch offers a better touch experience and remarkable immersion and ,more than 200 watch faces for you to choose from App"Da Fit ", you can change the dial style according to your mood to wear keeping the world on your wrist
- 【Accurate Activity Tracker Smart Watch 】sports watch activity tracker uses sweat and dust resistant breathable silicone strap, our Fitness Tracker Smart Watch for Android iOS Phones supports 12 sports modes,walking,running,bicycle,swimming,badminton,basketball,football,rope skipping. This bluetooth calls smart watch for men women is lightweight and stylish, bringing more convenient and relaxing sports experience while also providing more protection.
- 【Your 24 Hour Personal Daily Health Monitor】Fitness watch for women men full touch screen IP67 waterproof bluetooth smartwatch for Android iOS Phones with heart rate blood pressure monitor multifunction Andriod smart watch with steps counter sleep monitor sports fitness watch, monitoring blood oxygen saturation allows you to understand your physical condition in real time to track fitness progress ,to know your health status in time.
- 【More Functions Bluetooth Call Smart Watch】This fitness activity smart watch full screen for iPhone and Android phones includes a bunch of new features including:The bluetooth smart watch can hang up the phone, receive and display WhatsAPP /Text /Facebook /Twitter /Messenger reminder.Support sedentary reminder, alarm clock, stopwatch, timer,weather information,music control, remote camera control compatible with Android 5.0 and above or iOS 9.0 and above smartphones.
Keep wall time and elapsed time as separate fields
A record that needs both “when it happened” and “how long it took” should store both values explicitly. Store a UTC wall-clock timestamp for display and audit context, and store a monotonic duration or interval for performance and timeout logic. A monotonic reading has no stable meaning after reboot, so do not use it as a persisted date or as a cross-host identifier.
Diagnose the host before changing anything
First establish which service owns the system clock and whether the symptom is in the operating system or in application arithmetic.
- List likely synchronizers. Run
systemctl status chronyd systemd-timesyncdandtimedatectl status. Check enabled services and the distribution’s time-service configuration. If more than one daemon is active, stop or disable the competing service before selecting a leap policy. - Record the current state. Run
date -uandtimedatectl show. On a chrony-managed host, also runchronyc trackingandchronyc sources -v. Note the selected source, reachability, synchronization state, offset and leap status before editing configuration. - Correlate the symptom. Compare application logs with the daemon log and the host’s UTC clock. A single repeated second at a leap boundary is different from recurring one-second steps caused by an unstable source, a bad local clock or two daemons fighting.
- Inspect the code path. Search for subtraction, ordering or timeout calculations based on
time(),gettimeofday()orCLOCK_REALTIME. Replace those calculations withclock_gettime(CLOCK_MONOTONIC, ...). Keep realtime only where a civil timestamp is actually required. - Identify the upstream policy. Determine whether the NTP provider announces leap insertion/deletion or uses leap smearing. Smearing spreads the adjustment over a period chosen by the provider; it is not the same as an announced UTC leap event.
Configure chrony’s leap-second mode
In /etc/chrony/chrony.conf, or in the configuration file included by your distribution, set leapsecmode deliberately. Chrony provides four modes:
| Mode | Who performs the correction? | What happens to realtime? | When it fits | Trade-off |
|---|---|---|---|---|
system |
The kernel performs the leap step | The normal kernel leap behavior applies; an insertion can move the clock backward by one second | The default when the system driver supports leap seconds and kernel behavior is trusted | Applications that incorrectly treat realtime as monotonic can observe the jump |
step |
chronyd performs the step |
A one-second correction is applied by the daemon rather than through the kernel leap path | Systems where avoiding problematic kernel leap-second code paths is preferable | Realtime still changes abruptly, so application code must remain step-safe |
slew |
The correction is spread over time | No abrupt one-second jump; the clock remains temporarily offset while it is corrected | Applications cannot tolerate an instantaneous change and a short period of inaccuracy is acceptable | With Linux’s default maxslewrate, chrony documents a 12-second correction period |
ignore |
No dedicated leap correction from that chronyd instance | That instance does not apply the leap adjustment | Another time authority controls the system clock, or the architecture specifically requires this arrangement | Unsafe if no other correctly configured authority handles the leap |
The choice does not make CLOCK_REALTIME a monotonic clock. Even with step or slew, code that needs elapsed time must use a monotonic clock.
Rank #3
- [Low Noise High Fidelity] New bee guitar cord with 22AWG oxygen-free-copper center conductors provides enhanced signal transfer, the PVC insulation material and the high-density stranded copper double shield provide noise rejection for quiet operation
- [Ideal for Choice] New bee 1/4 straight and right angle metal connectors, ensures a secure connection in any instrument, pedal, or amp jack. L shape great fro on stage guitar stands
- [Wide Compatible] Suitable for mixer, power amplifier, microphone, effector, decoder, equalizer, electoronic organ, electric guitar, electric bass and other electronic equipments. Widely used in the installation of smart home, karaoke speaker, professional stage audio, etc
- [Easy Disassemble] Making incidental repairs quick and easy! Very nice, flexible cable
- [Dont Hesite to Order] 24 hours customer services and professional technology team are standing by
When to choose each mode
- Choose
systemwhen the kernel and your distribution’s time stack support leap seconds correctly and you want the standard kernel path. - Choose
stepwhen you need chronyd to own the correction and want to avoid a kernel leap-second path that has caused problems on the platform. - Choose
slewwhen preserving a smoothly changing wall clock matters more than being exactly aligned during the documented correction interval. - Choose
ignoreonly when a different, known authority is responsible. Do not use it as a generic way to hide timestamp errors.
Keep leap-second data current
If the reference clock does not reliably announce leap seconds, chrony can obtain the schedule and TAI-UTC information from the time-zone database with:
leapsectz right/UTC
Keep the system’s time-zone data updated so this information remains current. Chrony documents this verification command:
TZ=right/UTC date -d 'Dec 31 2008 23:59:60'
When the command accepts 23:59:60, the right/UTC data path is available. A restart is not required merely because the time-zone data has been updated, although you should follow your distribution’s normal procedure when changing chrony configuration itself.
Quick wins for a faster PC:
Repair Windows errors before they cause bigger problemsFix Now →Scan for outdated or missing drivers - takes under a minuteDriver Scan →Clear out junk files and repair common Windows errorsFree Scan →Do not add leapsectz right/UTC to a client that follows a leap-smearing NTP service. A smear provider intentionally presents a gradual timescale; independently applying the leap schedule can make the client apply the event twice or disagree with its source. For a smeared service, follow that provider’s documented client policy instead.
Rank #4
- Digital Family Calendar: BSIMB digital calendar wall touch screen puts an end to your chaotic life. Designed for busy families, the digital calendar keeps you organised and in step with your family. Assign different colours and tasks to each family member to make family scheduling easier and more intuitive.
- Easy Setup and Auto-Sync: Plug in, connect to WLAN and auto-syn your electric calendar in minutes. Digital wall calendar compatible with Google calendar, iCloud calendar, Outlook calendar, Cozi calendar and Yahoo calendar. Add events directly on the device or through the ecalendar app. Electronic calendar stays current whether you're at work or traveling—no manual updates needed.
- All-In-One Home Assistant: Smart calendar builds habits and encourage independence with personalised chores. Display daily meal plan to reduce the daily ‘What's for dinner?’ stress. To-do lists keep track of everything you want. Turning chores into valuable achievements with stars and rewards, making life easier and more enjoyable.
- Manage Anytime Anywhere: BSIMB electronic calendar for family stay connected with the powerful ecalendar app. Access and manage your digital wall calendar anytime, anywhere with free features like stars & rewards, photo screensaver, chore charts, meals plans, to-do lists etc. Electronic planner paid features like Magic Import tailor advanced tools for users with special needs.
- Stay in Touch with Loved Ones: Share photos or videos from your phone to electronic wall calendar with app, instantly update your life moment, and keep in touch with your family, especially those who are far away; you can also surprise your smart calendar digital wall by sending him a wish card; it's also great for keeping tech-illiterate elders in touch with the youngsters.
Apply the configuration safely
- Back up the configuration. Save the current chrony configuration and note the active source and tracking output so you can compare before and after.
- Edit one authority. Add or change exactly one
leapsecmodedirective in the active configuration. Addleapsectz right/UTConly when the upstream source does not reliably announce leap data and is not a smear source. - Use a controlled initial correction. If the host has a large initial offset, use chrony’s configured
makesteppolicy rather than rewriting timestamps already stored by applications. A step corrects the host clock; it cannot retroactively make an old wall-clock record correct. - Reload or restart the single active service. Use the service-management command appropriate for your distribution, then confirm that no competing daemon has taken ownership.
- Recheck tracking. Run
chronyc trackingandchronyc sources -v. Confirm that the expected source is reachable, the system is synchronized, the offset is bounded and the reported leap status matches the chosen policy. - Watch the logs. Look for repeated one-second steps, source changes, loss of synchronization or messages indicating that leap information is missing or conflicting.
What to do when the upstream server smears leap seconds
A leap smear deliberately changes the rate of the presented clock so applications do not see a one-second step. The smeared time is not identical to the UTC leap-second schedule during the smear window. Therefore, the client must use the provider’s smear-aware configuration and must not independently enable right/UTC-based leap insertion for that same path.
Mixing sources is especially dangerous: one source may announce a leap while another presents a smear. Keep a host’s sources on a consistent policy, and do not combine a smear source with an independently applied kernel or chrony leap correction.
Verify the repair
Use this checklist after changing the daemon or application:
Free tools Windows power users keep installed
One-click scans. No signup required.
- Exactly one service controls
CLOCK_REALTIME. timedatectlreports synchronization, or the selected daemon reports a valid reachable source and a bounded offset.chronyc trackingshows the expected leap status and a sensible reference source.chronyc sources -vconfirms that the selected source is reachable and not being continuously replaced.- If
right/UTCwas intentionally configured, the test command accepts23:59:60. - Application tests use monotonic deadlines and do not assume realtime timestamps strictly increase.
- Persisted records distinguish UTC wall-clock timestamps from elapsed-duration measurements.
- An independent trusted time source agrees with the host after correction.
Continue observing after the change. A single scheduled leap event is different from repeated one-second movements. Repeated steps usually indicate an unstable source, a large recurring offset, a service conflict or application code that is interpreting normal wall-clock correction as elapsed time.
Best Value
Common failure modes and their fixes
A timeout lasts too long or expires immediately
The usual cause is calculating a deadline with CLOCK_REALTIME. Move both the start reading and the deadline comparison to CLOCK_MONOTONIC. Keep the realtime value only if you also need to display when the timeout began.
Events appear out of order in logs
Log ordering based solely on UTC text can fail when the wall clock repeats a second or is corrected. Add a monotonic sequence or elapsed-time field for local ordering, while retaining UTC for correlation with external systems.
Two services keep changing the clock
Inspect systemctl status chronyd systemd-timesyncd, enabled units and distribution configuration. Stop or disable the unwanted service, then verify that the remaining daemon alone reports synchronization.
The host is synchronized but the application still reports a one-second error
Synchronization does not make realtime monotonic. Check whether the application subtracts wall-clock timestamps, assumes strict increase, or parses a leap-second label as an ordinary UTC value. Use monotonic APIs for elapsed calculations and define how the application represents a leap second in persisted data.
Applying right/UTC made the offset worse
Check whether the upstream service is a leap-smearing provider. Remove the directive for that client and follow the provider’s smear policy. Also verify that every active source uses the same leap convention.
Quick Recap
Design rules for reliable timestamp handling
- Use
CLOCK_REALTIMEfor civil meaning: “what date and UTC time did the user or auditor see?” - Use
CLOCK_MONOTONICfor elapsed meaning: “how long did this operation take?” - Use
CLOCK_MONOTONIC_RAWonly when excluding NTP rate adjustments is an explicit measurement requirement. - Use
CLOCK_TAIwhen a continuous atomic reference is required and every consumer understands TAI-UTC semantics. - Store wall-clock timestamps and durations in separate fields; never infer one from the other after a clock correction.
- Treat a one-second realtime reversal as a normal possibility in tests, not as an impossible state.
- Document the selected chrony leap mode and whether the upstream source announces or smears leap seconds.
Final decision guide
| Requirement | Clock or chrony choice | Reason |
|---|---|---|
| Retry timeout, socket deadline or job duration | CLOCK_MONOTONIC |
Unaffected by realtime steps and suitable for interval arithmetic |
| Raw performance measurement that should exclude NTP rate discipline | CLOCK_MONOTONIC_RAW |
Uses the raw hardware rate, with possible long-term drift from UTC |
| User-facing date or audit timestamp | CLOCK_REALTIME |
Represents civil time, but callers must tolerate correction and repeated seconds |
| Continuous atomic-time computation | CLOCK_TAI |
Avoids leap-second jumps when the application handles its semantics correctly |
| Trusted kernel leap handling | leapsecmode system |
Uses the standard kernel correction path |
| Kernel leap path is unsuitable | leapsecmode step |
Lets chronyd perform the correction |
| Applications require a gradual correction | leapsecmode slew |
Spreads the adjustment; Linux’s documented default is 12 seconds |
| Another authority owns the clock | leapsecmode ignore |
Prevents this chronyd instance from applying a duplicate dedicated correction |
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

