[SERVER-13270] mongo master slave replication Created: 19/Mar/14  Updated: 10/Dec/14  Resolved: 20/Mar/14

Status: Closed
Project: Core Server
Component/s: Replication
Affects Version/s: 2.4.6
Fix Version/s: None

Type: Question Priority: Major - P3
Reporter: RANJEET KUMAR Assignee: Thomas Rueckstiess
Resolution: Won't Fix Votes: 0
Labels: replication
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
duplicates SERVER-13468 mongo master slave replication Closed
is duplicated by SERVER-13283 mongo master slave replication Closed
Related
is related to SERVER-13468 mongo master slave replication Closed
Participants:

 Description   

I have set up a master slave replication in mongo.it will work fine for around 8 months.but sudeenly slave show too far behind master.then i Have increase the oplogsize in master upto 60 GB . and resync the slave.slave starts resyncing but after some time it will again start resync and this process is going so frequently.and slave never sync with master.i have checked the log file in slave and it show

Thu Mar 13 22:15:49.698 [replslave] Socket say send() errno:110 Connection timed out 10.209.135.54:27017
Thu Mar 13 22:15:49.805 [replslave] repl: DBException socket exception [SEND_ERROR] for 10.209.135.54:27017
Thu Mar 13 22:15:49.811 [replslave] Socket flush send() errno:110 Connection timed out 10.209.135.54:27017
Thu Mar 13 22:15:49.811 [replslave] caught exception (socket exception [SEND_ERROR] for 10.209.135.54:27017) in destructor (~PiggyBackData)
Thu Mar 13 22:15:49.838 [replslave] repl: sleep 2 sec before next pass



 Comments   
Comment by Thomas Rueckstiess [ 21/Jul/14 ]

Hi Ranjeet,

How many slave nodes do you have? Are you able to use a Replica Set instead of Master-Slave replication? If so, we recommend you switch to Replica Sets.

Please also note that the SERVER project is for reporting bugs or feature suggestions for the MongoDB server.

For MongoDB-related support discussion please post on the mongodb-user group (http://groups.google.com/group/mongodb-user) or Stack Overflow with the mongodb tag. A question like this involving more discussion would be best posted on the mongodb-user group.

Regards,
Thomas

Comment by RANJEET KUMAR [ 21/Jul/14 ]

Hi Matt,

Can you tell me the solution...What is the reason for time out..

Comment by Matt Dannenberg [ 21/Mar/14 ]

Ranjeet,

I was mistaken and I apologize. There is one reason we recommend users continue to use master-slave over replication and that is if they need more than 12 nodes. Otherwise replica sets are strongly preferred. One reason they are preferred is the issue you have come up against, which is that master-slave does not handle network problems gracefully.

Hope that gives you a little more insight into what you are seeing and what your options are.
Matt

Comment by Matt Dannenberg [ 20/Mar/14 ]

We have effectively deprecated master-slave and advising using replica sets for all replication. In the relatively near future we will be removing master-slave entirely.

Because of this, we do not actively diagnose master-slave issues and instead suggest upgrade to a replica set. If you are looking for community support or users who are actively using master-slave replication, we highly suggest joining or looking through the mongodb-user group ( https://groups.google.com/forum/#!forum/mongodb-user ).

Comment by RANJEET KUMAR [ 20/Mar/14 ]

please give me suggestion.why slave resync again and again.and replication breaks.

Generated at Thu Feb 08 03:31:11 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.