Jacques Posted July 18, 2012 Share Posted July 18, 2012 Hi Larry, Please advise on how to deal with the UTC time updates (code-wise), that happen every few years. Apparently the 1 second addition to UTC at the beginning of July this year played havoc with some web applications, including some popular social media sites. Regards, Jacques Apache 2.2.21 PHP 5.3.8 MySQL 5.0.8 Link to comment Share on other sites More sharing options...
HartleySan Posted July 20, 2012 Share Posted July 20, 2012 What do you mean exactly? Perhaps I'm not aware of the problem, but I would think this is something that your PHP installation on your server would take care of for you automatically. Am I wrong? Link to comment Share on other sites More sharing options...
Jacques Posted July 24, 2012 Author Share Posted July 24, 2012 Hi HartleySan, Below the link to the article on the 'UTC leap second issue' websites faced at the beginning of July this year I referred to previously. Is there a way of avoiding the UTC leap second issue apart from going the Google route which is most probably out of reach for your avearge web application developer? http://www.dailymail.co.uk/news/article-2167588/Leap-second-2012-Websites-crash-time-hiccup-caused-online-chaos.html Thank you. Link to comment Share on other sites More sharing options...
HartleySan Posted July 24, 2012 Share Posted July 24, 2012 That's fascinating. I just assumed that all hosted PHP servers would be connected to an NTP server that would take all this into account. I didn't realize it was such an issue. I'm amazed that Google had to go to such lengths to avoid any problems. I suppose a simple, yet inelegant, solution would be to simple take your site down for a minute or so around the leap second, just to insure that no DB insertions/updates occur during that extra second. My guess is that by the time this becomes an issue again in a couple of years, there will be better solutions available, which will most likely be automatically built into all PHP servers coordinated with an NTP server. Anyway, if Google's best engineers came up with the solution that they did, then I doubt anyone on this forum will be able to come up with a better one short of the software simply being upgraded to take such leap seconds into account. Link to comment Share on other sites More sharing options...
Larry Posted July 25, 2012 Share Posted July 25, 2012 I had not heard of this either. I do agree with Hartley here: if that's Google's answer, I doubt we could do better. It sounds to me like it ought to be addressed in the database application, though, and rather than take a sight done at the key second, you could just put up static content and queue all database transactions for the second in question. Link to comment Share on other sites More sharing options...
Jacques Posted July 27, 2012 Author Share Posted July 27, 2012 Thank you for the advice Hartley and Larry. We will definately incorporate it in our continuity strategy. Link to comment Share on other sites More sharing options...
Recommended Posts