Ntp support in erlang

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Ntp support in erlang

ARUN P
Hi,

     I am developing an erlang application which runs on a hardware
device and the device is connected in a network where a dedicated ntp
server is available. Now the difficulty what I am facing is that my
system time is not getting synced with ntp server, is there any support
available in erlang so that I can directly sync my system time with ntp
server by directly providing ntp server address.

Thanks in advance
Arun
_______________________________________________
erlang-questions mailing list
[hidden email]
http://erlang.org/mailman/listinfo/erlang-questions
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Ntp support in erlang

Jesper Louis Andersen-2
I think you would normally run a separate NTP client which calls into the kernel and sets the time accordingly. There are some very small NTP clients out there. I know Poul Henning Kamp is currently planning to do some work in the area[0] and ntimed is already there and a fairly small NTP client (and only a client).

As for the Erlang support, there is a couple of write-ups on how it handles the situation where the NTP client decides to move time suddenly. This is called a "warp", and how you configure your ERTS determines how it reacts. You have to pick the right solution for your situation:

http://erlang.org/doc/apps/erts/time_correction.html
http://learnyousomeerlang.com/time#time-warp


On Wed, Jan 25, 2017 at 9:31 AM Arun <[hidden email]> wrote:
Hi,

     I am developing an erlang application which runs on a hardware
device and the device is connected in a network where a dedicated ntp
server is available. Now the difficulty what I am facing is that my
system time is not getting synced with ntp server, is there any support
available in erlang so that I can directly sync my system time with ntp
server by directly providing ntp server address.

Thanks in advance
Arun
_______________________________________________
erlang-questions mailing list
[hidden email]
http://erlang.org/mailman/listinfo/erlang-questions

_______________________________________________
erlang-questions mailing list
[hidden email]
http://erlang.org/mailman/listinfo/erlang-questions
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Ntp support in erlang

Serge Aleynikov-3
In reply to this post by ARUN P
A while back I had to deal with the same issue and put together this module that obtained NTP time from servers:


Regards,

Serge

On Wed, Jan 25, 2017 at 3:30 AM, Arun <[hidden email]> wrote:
Hi,

    I am developing an erlang application which runs on a hardware device and the device is connected in a network where a dedicated ntp server is available. Now the difficulty what I am facing is that my system time is not getting synced with ntp server, is there any support available in erlang so that I can directly sync my system time with ntp server by directly providing ntp server address.

Thanks in advance
Arun
_______________________________________________
erlang-questions mailing list
[hidden email]
http://erlang.org/mailman/listinfo/erlang-questions


_______________________________________________
erlang-questions mailing list
[hidden email]
http://erlang.org/mailman/listinfo/erlang-questions
Loading...