Sync Windows and Linux clocks to the same time

Discussion in 'User Contributed Articles' started by Wolfie, Jul 10, 2017.

  1. Wolfie

    Wolfie

    Joined:
    Apr 22, 2017
    Messages:
    590
    Likes Received:
    79
    Hi all,

    anyone that uses Linux and Windows (dual boot), may well know the problem syncing the clocks between the 2 operating systems, a simple cheat to solve this problem below!. ;)

    Lie to one of the operating systems; as simple as that, I leave Windows showing "Set time automatically" and the correct zone (CET = Amsterdam, Berlin etc but not "Set time zone automatically") and tell Linux (Kubuntu 17.04 in this case) that I am in the Azores (take out tick for "Set date and time automatically"), this syncs both clocks and when you switch between the two, the clock still shows the correct time. :)

    If I don't lie to one of the systems, there is normally a 2 hour time difference, using the method above, both clocks always show the same time!. :):) You may need to play around with the different time zones depending on where you are in the world!. ;)

    My settings for both operating systems:

    Windows 10 Home Edition
    windows time settings.jpg

    Kubuntu 17.04
    Date & Time — System Settings Module_001.jpg

    Date & Time — System Settings Module_002.jpg
     
    Last edited: Jul 10, 2017
    Wolfie, Jul 10, 2017
    #1
    1. Advertisements

  2. Wolfie

    davehc Microsoft MVP

    Joined:
    Nov 19, 2013
    Messages:
    2,431
    Likes Received:
    444
    Location:
    Denmark
    I have no in depth knowledge of Linux. Isn't there a setting for Internet time? That is where I have my computers (Windows of course) pointing
     
    davehc, Jul 10, 2017
    #2
    1. Advertisements

  3. Wolfie

    Wolfie

    Joined:
    Apr 22, 2017
    Messages:
    590
    Likes Received:
    79
    HI Dave,

    the problem is that one of the systems will take command of the CMOS clock, when you switch between the two, the time is often off by 2 hours or more so lying to one of the systems as to where you really are; is something that solves the problem!. :)

    The problem with the automatic clock setting is that it simply doesn't work effectively when working with 2 different operating systems!. :( If both systems were Windows; it wouldn't make a difference to the time settings as far as I know?. ;)
     
    Wolfie, Jul 10, 2017
    #3
  4. Wolfie

    davehc Microsoft MVP

    Joined:
    Nov 19, 2013
    Messages:
    2,431
    Likes Received:
    444
    Location:
    Denmark
    Hmm. Not really understanding, I take your word for it.
    I only operate from one "Time" region, so where I am is not an issue.. I use, as I said, the "time.windows.com", an internet time server.
    I would have thought that LInux would be efficient in keeping its own time, regardless of whatever another OS was doing.. It does of course, axiomatically use the Cmos clock, there being no other standardised.. But in my case, I am only using one OS per computer, so only one would be using it.

    P.S. For example, it is now telling me it is time for a lunch beer or two.
     
    davehc, Jul 10, 2017
    #4
    Wolfie likes this.
  5. Wolfie

    Wolfie

    Joined:
    Apr 22, 2017
    Messages:
    590
    Likes Received:
    79
    HI Dave,

    under normal circumstances you could use the automatic time settings in both operating systems, the problem is that the clocks (on my PC's at least) are always out of sync with each other, as I said above; mostly by 2 hours!. :(:(

    I don't even mind getting data from the Azores, I'm sure they are very nice people!. :):):)

    Leave the beer alone and drink coffee, you will live longer according to the latest reports!. :p

    https://authoritynutrition.com/top-13-evidence-based-health-benefits-of-coffee/ ;)
     
    Wolfie, Jul 11, 2017
    #5
  6. Wolfie

    Tim Locke

    Joined:
    May 6, 2015
    Messages:
    1,707
    Likes Received:
    222
    Location:
    Guelph On
    Last time I used Linux ( Ubuntu) it automatically called up a time server at boot just as Windows does and was always correct. Why is your Linux machine set to the Azores rather than where you are. I am quite sure the Azores are full of nice people as well.
     
    Tim Locke, Jul 11, 2017
    #6
  7. Wolfie

    Wolfie

    Joined:
    Apr 22, 2017
    Messages:
    590
    Likes Received:
    79
    Wolfie, Jul 11, 2017
    #7
  8. Wolfie

    Tim Locke

    Joined:
    May 6, 2015
    Messages:
    1,707
    Likes Received:
    222
    Location:
    Guelph On
    This is silly. In your picture of Linux you show the time zone selected as the Azores. I guess you can scroll down to wherever you want. Right? When you do that do you hit Apply before hitting OK ? I have seen this before...bad UI programming imho as OK should imply Apply but certainly it doesn't on some applications.
     
    Tim Locke, Jul 11, 2017
    #8
  9. Wolfie

    Regedit32 Moderator

    Joined:
    Mar 4, 2016
    Messages:
    2,369
    Likes Received:
    639
    If the time is always wrong, maybe its time to check the cmos battery?!
     
    Regedit32, Jul 11, 2017
    #9
  10. Wolfie

    davehc Microsoft MVP

    Joined:
    Nov 19, 2013
    Messages:
    2,431
    Likes Received:
    444
    Location:
    Denmark
    Wolfie.", you will live longer according to the latest reports!. :p"

    OMG I could prove them Wrong at my age!!!!!!!
    - and, with sincerity, I hope not too much longer.
     
    davehc, Jul 11, 2017
    #10
    Wolfie likes this.
  11. Wolfie

    Wolfie

    Joined:
    Apr 22, 2017
    Messages:
    590
    Likes Received:
    79
    Hi Regedit32,

    it has everything to do with the UTC settings, the clocks (on both systems) should be set to "Local Time" and then there wouldn't be a problem, the problem is that when you install a Linux system in dual boot, you often don't get the chance to select using local time rather than UTC!. :)

    I could change Windows (or Linux via "root") using a script or playing around with the registry/system files but I really don't want to start advising people to muck around with their reg lists!. :eek:

    Hi Tim,

    I selected the Azores as the best option for my timezone which is Central Europe, I could of course select a different timezone but the clock would be off again!. :( When I set my timezone during an Ubuntu install, I don't recall seeing a setting for local time or UTC, or am I wrong?. o_O

    Hi Dave,

    the mother of my best friend will be 96 in a few days time, she has often said to me that she prays at night to "go", she is a great old Irish girl and even at her age; one can still have a good chat with her, the world will be a sadder place without her (for me at least!). :)
     
    Last edited: Jul 12, 2017
    Wolfie, Jul 12, 2017
    #11
  12. Wolfie

    Regedit32 Moderator

    Joined:
    Mar 4, 2016
    Messages:
    2,369
    Likes Received:
    639

    Fair enough Wolfie. I must admit, after posting my query, the thought crossed my mind that if it were a battery issue then the windows clock would also be out of sync, not just the linux one. I have not bothered dual booting anything thus far with Windows 10 so have not had a chance to explore any particular niggles that might come with doing that.

    I might have a go in the weekend to test things as I have several linux distros lying around and its about time I saw how well they perform in combination with Windows 10. When I get a chance to I'll make sure to note the install process to see whether there are any options to work-around this issue you've highlighted.

    I do not recall such as issue back in Vista or windows 7 days, but perhaps I just never noticed.
     
    Regedit32, Jul 12, 2017
    #12
    Wolfie likes this.
  13. Wolfie

    Wolfie

    Joined:
    Apr 22, 2017
    Messages:
    590
    Likes Received:
    79
    Hi Regedit32,

    please let me know, as far as I know; there isn't a time setting option during an Ubuntu install but I can't remember for the life of me!. It would be a nice option to have, I know that PCLinuxOS has it; as do several other versions of Linux, I don't think Ubuntu has this option though and hence the problem!. ;)

    THe following link is a fix-it for Ubuntu (I'm using Kubuntu 17.04) but it is a tad old, most likely fact is that I didn't install "NTP" which I need to take a look at.

    https://help.ubuntu.com/community/UbuntuTime

    The thread starter is still an easy fix for the non-techies out there which is what I aimed at!. :)
     
    Last edited: Jul 12, 2017
    Wolfie, Jul 12, 2017
    #13
  14. Wolfie

    Regedit32 Moderator

    Joined:
    Mar 4, 2016
    Messages:
    2,369
    Likes Received:
    639
    Will do Wolfie.

    I thought you just had to install the NTP daemon although that may only be with Servers, we'll see in the weekend.

    Code:
    sudo apt-get install ntp
    Then grab the config file and select the server:

    Code:
    sudo nano /etc/ntp.conf
    Then you ensure a more accurate time setting use the appropriate regional setting, which in your case is probably:

    Code:
    europe.pool.ntp.org
    Anyway, we'll see during the weekend how things go.

    In time I'll know I guess *pun fully intended* :D
     
    Regedit32, Jul 12, 2017
    #14
    Wolfie likes this.
  15. Wolfie

    Wolfie

    Joined:
    Apr 22, 2017
    Messages:
    590
    Likes Received:
    79
    That is right Regedit32, the problem lies with the fact that there isn't an option (as fas as I am aware of) to set the clock to local time during the install on an Ubuntu (based) system!. o_O

    Anyway, let me know what happens and when I get more time; I will check out what KDE's (Kubuntu's) needs are!. :)
     
    Wolfie, Jul 12, 2017
    #15
  16. Wolfie

    davehc Microsoft MVP

    Joined:
    Nov 19, 2013
    Messages:
    2,431
    Likes Received:
    444
    Location:
    Denmark
    "the mother of my best friend will be 96 in a few days time, she has often said to me that she prays at night to "go", she is a great old Irish girl and even at her age; one can still have a good chat with her, the world will be a sadder place without her (for me at least"

    A childhood prayer I remember:
    Now I lay me down to sleep,
    I pray the lord, my sould shall keep..etc

    Anyway, sorry, nothing to do with Linux clocks.
     
    davehc, Jul 12, 2017
    #16
    Wolfie likes this.
  17. Wolfie

    Wolfie

    Joined:
    Apr 22, 2017
    Messages:
    590
    Likes Received:
    79
    Not a problem Dave, my clocks are still synced and that is really what the thread starter is about but that's not to say we can't have a friendly chat with each other!. :)

    I am a great believer in keeping it as simple as possible:

    https://en.wikipedia.org/wiki/KISS_principle :)

    Hi @Regedit32,

    just to let you know that I installed the package "ntp" in Kubuntu, I then reset the Kubuntu clock to run automatically and then checked Windows and the time was off by 2 hours again!. :(:( Using NTP would mean changing settings (edit the reg) in Windows as well as Kubuntu by the look of things?. o_O
     
    Last edited: Jul 13, 2017
    Wolfie, Jul 13, 2017
    #17
  18. Wolfie

    Regedit32 Moderator

    Joined:
    Mar 4, 2016
    Messages:
    2,369
    Likes Received:
    639
    :mad:
     
    Regedit32, Jul 13, 2017
    #18
    1. Advertisements

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Similar Threads
  1. davidhk129

    I am dsiappointed and at the same time ..........

    davidhk129, Apr 18, 2015, in forum: Off-Topic Discussion
    Replies:
    2
    Views:
    665
    davehc
    Apr 19, 2015
  2. David Tuff

    Sync Centre - Setup New Sync Partnerships

    David Tuff, Sep 1, 2015, in forum: Windows 10 Support
    Replies:
    3
    Views:
    2,774
    Quinco
    Nov 28, 2015
  3. Lorraine W
    Replies:
    0
    Views:
    607
    Lorraine W
    Sep 10, 2015
  4. martinjdn
    Replies:
    6
    Views:
    1,180
    Graperain
    Nov 22, 2016
  5. WalkingDrum

    SOLVED Two websites at same time

    WalkingDrum, Oct 28, 2015, in forum: Windows 10 Support
    Replies:
    2
    Views:
    469
    WalkingDrum
    Oct 30, 2015
  6. Tamarbri

    Windows 10 and Linux EXT3

    Tamarbri, Jul 26, 2016, in forum: Windows 10 Support
    Replies:
    2
    Views:
    672
    BigFeet
    Jul 26, 2016
  7. drin kadriu
    Replies:
    9
    Views:
    446
  8. NecrosoftCore

    SUSE Linux now on the Windows Store

    NecrosoftCore, Jun 25, 2017, in forum: Software
    Replies:
    7
    Views:
    179
    BigFeet
    Jul 12, 2017
Loading...