Your Ubuntu clock is wrong again - maybe by minutes, maybe by exactly five and a half hours. The mistake most people make is fixing the clock face instead of the cause. There are two clocks in your PC, and this guide finds out which one is lying before touching a single setting.
Every computer keeps time in two places. The RTC (real-time clock) is a small hardware clock on the motherboard that keeps ticking on battery power while the PC is off. The system clock is what Ubuntu shows you while it runs, and it is corrected over the internet by a sync service called NTP. At boot, Ubuntu reads the RTC and builds the system clock from it. So a wrong clock means one of three things: the RTC held the wrong value, Ubuntu read it with the wrong assumption, or the internet correction never happened. One command separates all three.
Open a terminal and run timedatectl. You do not need sudo just to look. Seven lines appear; six of them matter:
Asia/Kolkata (IST, +0530)Write down what your screen shows before changing anything. Two minutes of reading here saves an hour of random fixes.
Wrong time is not one problem. The size and shape of the error names the culprit almost every time:
Each pattern has its own fix in the guides linked from this page. Fixing the wrong pattern is why the problem keeps coming back.
Most single-boot Ubuntu machines heal themselves if sync is allowed to run. Check it is on:
timedatectl set-ntp true (it will ask for your password)timedatectl againIf it stays on no, the sync service or the network is blocking it - that is a separate fault with its own guide, because the fix is about the service and UDP port 123, not about the clock.
If the zone itself is wrong, everything else looks broken. Set it once, properly:
timedatectl output, on the Time zone linetimedatectl list-timezones - names are case-sensitive and use slashes, like Asia/Kolkatasudo timedatectl set-timezone Asia/Kolkatatimedatectl again and confirm the Local time line now shows the time on your wall clockStill wrong after this, with the right zone showing? Then the zone was never the problem - go back to the pattern list in step 2.
On a dual-boot machine you must pick one convention and make both systems agree. Ubuntu's default is the sane one: the RTC holds UTC (RTC in local TZ: no) and each OS converts for display. Windows defaults to the opposite: it treats the RTC as local time.
timedatectl set-local-rtc 1 --adjust-system-clock - Ubuntu then reads and writes the RTC the way Windows expectsRealTimeIsUniversal registry value, leaving Ubuntu at its clean defaultBoth routes have their own detailed guides in this series, with the grading of which one suits which machine.
Once the system clock is correct and synchronized, store that correct value into the RTC so the next cold boot starts right:
timedatectl shows the correct Local and Universal time, with synchronized: yessudo hwclock --systohc - this copies the system time into the hardware clocksudo hwclock --showIf the time is wrong again after a full power-off even now, software has done all it can - suspect the CMOS battery or a drifting RTC on old hardware, and test that honestly instead of reinstalling anything.
timedatectl instead of setting the time by hand again and again; a clock you correct daily is a fault you have not found yet.The full Ubuntu time troubleshooting video - dual boot fights, sync failures and the timedatectl checks, shown live, step by step.
Watch Full VideoWindows writes the hardware clock as local time and Ubuntu reads it as UTC, so every switch moves the clock by your zone offset. Pick one convention - either timedatectl set-local-rtc 1 on the Ubuntu side, or the RealTimeIsUniversal value on the Windows side - never both.
It is a built-in, supported command and it is the standard quick fix for Windows dual boots. Timedatectl itself warns that local RTC mode is not fully supported and can misbehave around daylight-saving changes and multi-boot setups. India has no daylight saving, so for most Indian home users the practical risk is low - but know the trade before you take it.
Small errors are almost never a settings problem. Either internet sync is off or failing (the synchronized line in timedatectl says no), or the hardware clock is drifting as it ages. Turn sync on first; if the error keeps growing with sync on, suspect the hardware, including a weak CMOS battery on older machines.