How does one make sure or even guarantee server time are sync correctly between dozens of servers across multiple datacenter on different location?

Posted by forestclown on Server Fault See other posts from Server Fault or by forestclown
Published on 2011-08-31T02:07:09Z Indexed on 2012/07/09 15:18 UTC
Read the original article Hit count: 298

Filed under:
|
|

Currently our web applications contain a logic to check if the data sent to the web server is expired or not by comparing the timestamp of the data with the date/time of the server.

Everything goes will, until some dude from data center accidentally modify one of the web server date/time and causes some disruptions in our web services. My managers are of course not happy with this, and said we shouldn't use timestamp to check expiry in the first place...anyway....

Network Time Protocol is implemented, because of data centers are spread across different continents so we have one NTP server in each data center. The servers within the data center will have cron jobs to check against the time with their NTP server from the same data center. If time is out of sync it will auto update the server date/time.

But then with our managers not happy with it, and think it could still easily causes the same problem. e.g. what if someone accidentally modify the NTP date/time? what if all the NTP servers are out of sync with each other? which NTP servers we can really trust? and blah blah..

So my questions are:

  1. What are the current practice to sync date/time between servers across multiple data centers or locations?
  2. How does one manages time stamp between web apps? e.g. Server A send data (contain timestamp of Server A) to Server B (compare timestamp between Server B and the timestamp from the data to see if it has expired or not. This is to avoid HTTP replay)
  3. Should we really not use timestamp check?

Thanks & Best Regards

© Server Fault or respective owner

Related posts about ntp

Related posts about sync