[SERVER-12135] rs.syncFrom does not display an error during initial sync Created: 16/Dec/13  Updated: 09/Jul/16  Resolved: 11/Jun/14

Status: Closed
Project: Core Server
Component/s: Shell
Affects Version/s: 2.2.6, 2.4.8
Fix Version/s: None

Type: Bug Priority: Major - P3
Reporter: Sam Neubardt Assignee: Ramon Fernandez Marina
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Operating System: ALL
Participants:

 Description   

http://docs.mongodb.org/manual/tutorial/configure-replica-set-secondary-sync-target/ indicates that if an initial sync is already in progress then rs.syncFrom will have no effect, nor will it display an error. This command shouldn't silently fail. It should display an error in the shell indicating that it didn't succeed.

The output:

rs.syncFrom("HOST:27017")
{ "syncFromRequested" : "HOST:27017", "ok" : 1 }

doesn't indicate that nothing will happen until the initial sync completes.

The docs for rs.syncFrom http://docs.mongodb.org/manual/reference/method/rs.syncFrom/
and replSetSyncFrom http://docs.mongodb.org/manual/reference/replica-commands/#dbcmd.replSetSyncFrom
could indicate this better. The only mention of this behavior is on the page linked at the beginning of this report.



 Comments   
Comment by Ramon Fernandez Marina [ 11/Jun/14 ]

rs.syncFrom() is a shell helper for {{replSetSyncFrom }}, where this behavior is documented.

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