JavaScript NTP time

First of all, the JS scheduler has a certain granularity – that is, you can request an interval smaller than, say, 20 msec, but it will not fire immediately – what you could see is 20 events fired off every 20 msec. Second, even if you could, this is not a good idea: you would … Read more

Network Time Protocol for iPhone

There’s a small iOS library named ios-ntp. I have used it in one project in the past and it seemed to work reasonably well. As of mid 2013 the original ios-ntp project has a few missing pieces, so I have mirrored the original svn repository to github. You can checkout out a working version of … Read more

Will a docker container auto sync time with its host machine?

If you are on OSX running boot2docker, see this issue: https://github.com/boot2docker/boot2docker/issues/290 Time synch becomes an issue because the boot2docker host has its time drift while your OS is asleep. Time synch with your docker container cannot be resolved by running your container with -v /etc/localtime:/etc/localtime:ro Instead, for now, you have to periodically run this on … Read more

How to Query an NTP Server using C#?

Since the old accepted answer got deleted (It was a link to a Google code search results that no longer exist), I figured I could answer this question for future reference : public static DateTime GetNetworkTime() { //default Windows time server const string ntpServer = “time.windows.com”; // NTP message size – 16 bytes of the … Read more