Synchronization (of clocks) between two remote computers

前端 未结 9 1068
隐瞒了意图╮
隐瞒了意图╮ 2020-12-05 05:40

I\'m looking into writing a simple synchronization ability into my app and one of the concerns that has popped up is synchronization of time between two remote computers, ea

相关标签:
9条回答
  • 2020-12-05 06:11

    Look at "Network Time Protocol" (NTP) specification.

    0 讨论(0)
  • 2020-12-05 06:12

    Synchronize them with NTP Network Time Protocol.

    What platform are you on?

    With NTP you can synchronize the time of your computers with atomic clocks and use the official time of the world.

    0 讨论(0)
  • 2020-12-05 06:14

    One thing we do is essentially offload all timing operations to the 'host' machine. For example, if you have 20 servers that all share a DB, use the DB's time. If you have a central server and a million client machines, then the client machines shouldn't be responsible for timing anything; do all your syncing server-side. In a truly 'distributed' environment, like a P2P network or something, use the machine that most directly 'owns' the resource in question (the actual PC the file you want to write) to syncronize/control access to the file.

    0 讨论(0)
提交回复
热议问题