Running multiple sync_clients

Bron Gondwana brong at
Thu Nov 18 16:40:29 EST 2010

On Thu, Nov 18, 2010 at 12:58:10PM -0500, Michael D. Sofka wrote:
> Is it safe to run multiple sync_clients?  Is there an advantage to doing so?
> I had to restart sync_client once.  After later restarting cyrus two 
> sync_clients were running, and appeared to do well together.  Still, I 
> stopped the old process out of caution.

What version?  In 2.3.x, the sync_server will obtain a lock, so you can
only run one sync_server at a time.  This means the sync_clients will
take it in turns sending data.

In 2.4, there is no global locking - just locks on each mailbox.  So it's
possible for two sync_clients to run at the same time.  There is a
possibility this will lead to the same data being sent twice.  It won't
cause corruption, but it will cause excess IO!

Are you sure it's actually two sync_client instances?  In every released
version, sync_client forks immediately upon starting and then forks again
to actually send data.

Which is a problem because it opens the BDB environment once and closes it
many times.  So I've now changed it on my development branch to not fork
the second time, but just keep it all in once process.  We'll see if there
are actually any memory leaks left!


More information about the Info-cyrus mailing list