472,108 Members | 1,382 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,108 software developers and data experts.

Time management b/w two server


We have two server one in India and canada, and replication is set up in both mysql database, and its working fine. But the problem arises when i insert a query here using now() function in one server and when i see the result in same server it shows correct time, when i see in other server it is not showing the local time of other server, it shows two hours diffence time.

example: If in Indian server i fire a query using now() function and when i see in indian server i see the same time , but in canada server server i see two hours diff then that of canada local time.

can any one help me how to solve this issue, Thanks in advance.
Aug 31 '07 #1
3 1068
802 Expert 512MB
In slave server, it saves the data with time which saved on master server not NOW(). The replication slaves have the exact data of master server.
Aug 31 '07 #2
Thanks for your reply.
In slave its saving different time. Not the same time.
Sep 3 '07 #3
802 Expert 512MB
Do you have the same time zone on both the servers?MySQL Manual says...
The same system time zone should be set for both master and slave. Otherwise some statements will not be replicated properly, such as statements that use the NOW() or FROM_UNIXTIME() functions.
Sep 3 '07 #4

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

3 posts views Thread by Andrew Robinson | last post: by
3 posts views Thread by Liming | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.